Skip to content
This repository has been archived by the owner on Oct 13, 2024. It is now read-only.

fix(ui): url encode item titles in issue url #330

Merged
merged 1 commit into from
Jan 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion Contents/Code/webapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
from flask import Flask, Response, render_template, send_from_directory
from flask_babel import Babel
import polib
from six.moves.urllib.parse import quote_plus
from werkzeug.utils import secure_filename

# local imports
Expand Down Expand Up @@ -316,7 +317,11 @@ def cache_data():
Log.Error('Error getting collection data from LizardByte db: {}'.format(e))
database_id = None

item_issue_url = issue_url.format(issue_title, database_id) if database_id else None
if database_id:
# url encode the issue title
issue_title = quote_plus(issue_title)

item_issue_url = issue_url.format(issue_title, database_id)

if database_type and themerr_db_helper.item_exists(
database_type=database_type,
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ plexapi-backport[alert]==4.15.6 # custom python-plexapi supporting python 2.7
polib==1.2.0;python_version<"3"
requests==2.27.1;python_version<"3" # 2.27 is last version supporting Python 2.7
schedule==0.6.0;python_version<"3"
six==1.16.0;python_version<"3"
typing==3.10.0.0
werkzeug==1.0.1;python_version<"3"

Expand Down
Loading