From 7243553366572e8631f4d2d66909bbd938fa6ab2 Mon Sep 17 00:00:00 2001 From: sadrasabouri Date: Fri, 22 Oct 2021 13:36:13 +0330 Subject: [PATCH] fix : isinstance file --> IOBase. --- samila/functions.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samila/functions.py b/samila/functions.py index 76959ad..d4b325c 100644 --- a/samila/functions.py +++ b/samila/functions.py @@ -230,7 +230,7 @@ def load_data(data): :type data: (io.IOBase & file) :return: (data1, data2) """ - if isinstance(data, (file, io.IOBase)): + if isinstance(data, io.IOBase): data = json.load(data) if 'data1' not in data or 'data2' not in data: raise samilaDataError(DATA_PARSING_ERROR)