Skip to content

Commit

Permalink
Fix mypy error
Browse files Browse the repository at this point in the history
  • Loading branch information
sanders41 committed Dec 5, 2021
1 parent efab68b commit cede993
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions meilisearch/index.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import urllib
from urllib import parse
from datetime import datetime
from time import sleep
from typing import Any, Dict, Generator, List, Optional, Union
Expand Down Expand Up @@ -313,7 +313,7 @@ def get_documents(self, parameters: Optional[Dict[str, Any]] = None) -> List[Dic
if parameters is None:
parameters = {}
return self.http.get(
f'{self.config.paths.index}/{self.uid}/{self.config.paths.document}?{urllib.parse.urlencode(parameters)}'
f'{self.config.paths.index}/{self.uid}/{self.config.paths.document}?{parse.urlencode(parameters)}'
)

def add_documents(
Expand Down Expand Up @@ -1240,5 +1240,5 @@ def _build_url(
) -> str:
if primary_key is None:
return f'{self.config.paths.index}/{self.uid}/{self.config.paths.document}'
primary_key = urllib.parse.urlencode({'primaryKey': primary_key})
primary_key = parse.urlencode({'primaryKey': primary_key})
return f'{self.config.paths.index}/{self.uid}/{self.config.paths.document}?{primary_key}'

0 comments on commit cede993

Please sign in to comment.