From 1f18e505ab9797bb945c1bf5e89b3cdb0f8bdc2e Mon Sep 17 00:00:00 2001 From: "Joao A. Candido Ramos" Date: Thu, 18 Nov 2021 00:17:27 +0100 Subject: [PATCH] Include "chips" param in image search (#534) "chips" is used in image tabs to pass the optional "filter" to add to the given search term Fixes #299 --- app/request.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/request.py b/app/request.py index 6d25224..da8852a 100644 --- a/app/request.py +++ b/app/request.py @@ -115,6 +115,11 @@ def gen_query(query, args, config, near_city=None) -> str: if 'nfpr' in args: param_dict['nfpr'] = '&nfpr=' + args.get('nfpr') + # 'chips' is used in image tabs to pass the optional 'filter' to add to the + # given search term + if 'chips' in args: + param_dict['chips'] = '&chips=' + args.get('chips') + param_dict['cr'] = ('&cr=' + config.ctry) if config.ctry else '' param_dict['hl'] = '&hl=' + ( config.lang_interface.replace('lang_', '')