We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 37b4e6a commit d0832bdCopy full SHA for d0832bd
jokeapi/main.py
@@ -15,7 +15,6 @@ def __init__(self):
15
self.http = urllib3.PoolManager()
16
self.info = self.http.request('GET', "https://sv443.net/jokeapi/v2/info")
17
self.info = data = json.loads(self.info.data.decode('utf-8'))["jokes"]
18
- print("Sv443's JokeAPI")
19
20
def build_request(
21
self,
@@ -32,7 +31,7 @@ def build_request(
32
31
33
if len(category):
34
for c in category:
35
- if not c.lower() in self.info["categories"]:
+ if not c.title() in self.info["categories"]:
36
raise ValueError(
37
f'''Invalid category selected.
38
You selected {c}.
0 commit comments