Skip to content

Commit 5b9d310

Browse files
authored
Merge pull request #56 from chimd715/master
Fix: API client to normalize only booleans not integers
2 parents 5d1b740 + 9f89ac1 commit 5b9d310

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/typesense/api_call.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,9 @@ def set_node_healthcheck(self, node, is_healthy):
136136
@staticmethod
137137
def normalize_params(params):
138138
for key in params.keys():
139-
if params[key] == True:
139+
if isinstance(params[key], bool) and params[key]:
140140
params[key] = 'true'
141-
elif params[key] == False:
141+
elif isinstance(params[key], bool) and not params[key]:
142142
params[key] = 'false'
143143

144144
def get(self, endpoint, params=None, as_json=True):

0 commit comments

Comments
 (0)