diff options
author | Mohamed Elashri <muhammadelashri@gmail.com> | 2022-09-30 23:06:54 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-30 23:06:54 +0000 |
commit | 8d5653e60d5299979c0de5e55b1c5ca0bee8190c (patch) | |
tree | 8dc02b7663a5c9c91b09483e4499a612d9823698 /searx/utils.py | |
parent | 212c98c9f55dc602f57b4f01a73192450e9782b7 (diff) | |
parent | 62324655ff0d2e6f234b3e31413877b4b4a7a9fa (diff) | |
download | searxng-8d5653e60d5299979c0de5e55b1c5ca0bee8190c.tar.gz searxng-8d5653e60d5299979c0de5e55b1c5ca0bee8190c.zip |
Merge branch 'searxng:master' into master
Diffstat (limited to 'searx/utils.py')
-rw-r--r-- | searx/utils.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/searx/utils.py b/searx/utils.py index 4910b1b85..effb9139a 100644 --- a/searx/utils.py +++ b/searx/utils.py @@ -273,7 +273,7 @@ def extract_url(xpath_results, base_url) -> str: raise ValueError('URL not found') -def dict_subset(dictionnary: MutableMapping, properties: Set[str]) -> Dict: +def dict_subset(dictionary: MutableMapping, properties: Set[str]) -> Dict: """Extract a subset of a dict Examples: @@ -282,7 +282,7 @@ def dict_subset(dictionnary: MutableMapping, properties: Set[str]) -> Dict: >>> >> dict_subset({'A': 'a', 'B': 'b', 'C': 'c'}, ['A', 'D']) {'A': 'a'} """ - return {k: dictionnary[k] for k in properties if k in dictionnary} + return {k: dictionary[k] for k in properties if k in dictionary} def get_torrent_size(filesize: str, filesize_multiplier: str) -> Optional[int]: |