Skip to content

Commit

Permalink
Merge pull request #274 from mtunique/origin/fixutf-8
Browse files Browse the repository at this point in the history
Fix some unicode encode issues
  • Loading branch information
nate-parrott committed Jan 18, 2015
2 parents 71593e7 + 959928a commit badb07e
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 18 deletions.
4 changes: 2 additions & 2 deletions PluginDirectories/1/1688.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
url = i18n.localstr(url)
search_url = url + urllib.quote_plus(parsed[key])
search_url = url + urllib.quote_plus(parsed[key].encode('utf-8'))
return {
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]),
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8')),
"run_args": [search_url],
"html": """
<script>
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/alibaba.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
url = i18n.localstr(url)
search_url = url + urllib.quote_plus(parsed[key])
search_url = url + urllib.quote_plus(parsed[key].encode('utf-8'))
return {
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]),
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8')),
"run_args": [search_url],
"html": """
<script>
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/aliexpress.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
url = i18n.localstr(url)
search_url = url + urllib.quote_plus(parsed[key])
search_url = url + urllib.quote_plus(parsed[key].encode('utf-8'))
return {
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]),
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8')),
"run_args": [search_url],
"html": """
<script>
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/bing.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
localizedurl = i18n.localstr(url)
search_url = localizedurl + urllib.quote_plus(parsed[key])
title = i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]);
search_url = localizedurl + urllib.quote_plus(parsed[key].encode('utf-8'))
title = i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8'))
return {
"title": title,
"run_args": [search_url],
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/ebay.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
url = i18n.localstr(url)
search_url = url + urllib.quote_plus(parsed[key])
search_url = url + urllib.quote_plus(parsed[key].encode('utf-8'))
return {
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]),
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8')),
"run_args": [search_url],
"html": """
<script>
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/jd.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
url = i18n.localstr(url)
search_url = url + urllib.quote_plus(parsed[key])
search_url = url + urllib.quote_plus(parsed[key].encode('utf-8'))
return {
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]),
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key.encode('utf-8')]),
"run_args": [search_url],
"html": """
<script>
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/yahoo.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
localizedurl = i18n.localstr(url)
search_url = localizedurl + urllib.quote_plus(parsed[key])
title = i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]);
search_url = localizedurl + urllib.quote_plus(parsed[key].encode('utf-8'))
title = i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8'))
return {
"title": title,
"run_args": [search_url],
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/yhd.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
url = i18n.localstr(url)
search_url = url + urllib.quote_plus(parsed[key])
search_url = url + urllib.quote_plus(parsed[key].encode('utf-8'))
return {
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]),
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8')),
"run_args": [search_url],
"html": """
<script>
Expand Down
4 changes: 2 additions & 2 deletions PluginDirectories/1/yixun.bundle/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def results(parsed, original_query):
for name, key, url in search_specs:
if key in parsed:
url = i18n.localstr(url)
search_url = url + urllib.quote_plus(parsed[key])
search_url = url + urllib.quote_plus(parsed[key].encode('utf-8'))
return {
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key]),
"title": i18n.localstr("Search {0} for '{1}'").format(name, parsed[key].encode('utf-8')),
"run_args": [search_url],
"html": """
<script>
Expand Down

0 comments on commit badb07e

Please sign in to comment.