Skip to content

Commit 0676c6a

Browse files
committed
Renamed ZooResult to ZooItemResult. Users will have a different result object. fixed a small get_item hiccup
1 parent a43dd2c commit 0676c6a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pyzootool/items.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
from pyzootool import ROOT_URL
55

6-
class ZooResult():
6+
class ZooItemResult():
77

88
def __init__(self, json_data):
99
self.parse_results(json_data)
@@ -33,8 +33,8 @@ def get_item(self, item_id):
3333
)
3434
resp, content = self.http.request(url)
3535
json_data = json.loads(content)
36-
result = ZooResult(item)
37-
return zoo_results
36+
result = ZooItemResult(item)
37+
return result
3838

3939
def get_popular(self, pop_type):
4040
values = {'type': pop_type, 'apikey': self.apikey }
@@ -45,6 +45,6 @@ def get_popular(self, pop_type):
4545
json_data = json.loads(content)
4646
zoo_results = []
4747
for item in json_data:
48-
result = ZooResult(item)
48+
result = ZooItemResult(item)
4949
zoo_results.append(result)
5050
return zoo_results

0 commit comments

Comments
 (0)