Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix 500 error when inputs contain ints #347

Merged
merged 1 commit into from
Feb 10, 2025
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
4 changes: 2 additions & 2 deletions templates/010-plex.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</span>
</span>
<input type="text" class="form-control" id="plex_url" name="plex_url"
value="{{ data['plex']['url'] if data['plex']['url'] and 'http://192.168.1.12:32400' not in data['plex']['url'] else '' }}"
value="{{ data['plex']['url'] | string if data['plex']['url'] and 'http://192.168.1.12:32400' not in data['plex']['url'] | string else '' }}"
aria-describedby="plex_url_text">
</div>
<div class="input-group mb-2">
Expand All @@ -24,7 +24,7 @@
</span>
</span>
<input type="password" class="form-control" id="plex_token" name="plex_token"
value="{{ data['plex']['token'] if data['plex']['token'] and 'Enter Plex Token' not in data['plex']['token'] else '' }}"
value="{{ data['plex']['token'] | string if data['plex']['token'] and 'Enter Plex Token' not in data['plex']['token'] | string else '' }}"
aria-describedby="plex_url_text">
<button class="btn btn-outline-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
2 changes: 1 addition & 1 deletion templates/020-tmdb.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</span>
</span>
<input type="password" class="form-control" id="tmdb_apikey" name="tmdb_apikey"
value="{{ data['tmdb']['apikey'] if data['tmdb']['apikey'] and 'Enter TMDb API Key' not in data['tmdb']['apikey'] else '' }}"
value="{{ data['tmdb']['apikey'] | string if data['tmdb']['apikey'] and 'Enter TMDb API Key' not in data['tmdb']['apikey'] | string else '' }}"
aria-describedby="tmdb_apikey_text">
<button class="btn btn-outline-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
4 changes: 2 additions & 2 deletions templates/030-tautulli.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</span>
</span>
<input type="text" class="form-control" id="tautulli_url" name="tautulli_url"
value="{{ data['tautulli']['url'] if data['tautulli']['url'] and 'http://192.168.1.12:8181' not in data['tautulli']['url'] else '' }}"
value="{{ data['tautulli']['url'] | string if data['tautulli']['url'] and 'http://192.168.1.12:8181' not in data['tautulli']['url'] | string else '' }}"
aria-describedby="tautulli_url_text">
</div>

Expand All @@ -24,7 +24,7 @@
</span>
</span>
<input type="password" class="form-control" id="tautulli_apikey" name="tautulli_apikey"
value="{{ data['tautulli']['apikey'] if data['tautulli']['apikey'] and 'Enter Tautulli API Key' not in data['tautulli']['apikey'] else '' }}"
value="{{ data['tautulli']['apikey'] | string if data['tautulli']['apikey'] and 'Enter Tautulli API Key' not in data['tautulli']['apikey'] | string else '' }}"
aria-describedby="tautulli_apikey_text">
<button class="btn btn-outline-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
2 changes: 1 addition & 1 deletion templates/040-github.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</span>
</span>
<input type="password" class="form-control" id="github_token" name="github_token"
value="{{ data['github']['token'] if data['github']['token'] and 'Enter GitHub Personal Access Token' not in data['github']['token'] else '' }}"
value="{{ data['github']['token'] | string if data['github']['token'] and 'Enter GitHub Personal Access Token' not in data['github']['token'] | string else '' }}"
aria-describedby="github_token_text">
<button class="btn btn-outline-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
2 changes: 1 addition & 1 deletion templates/050-omdb.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="password" class="form-control" id="omdb_apikey" name="omdb_apikey"
value="{{ data['omdb']['apikey'] if data['omdb']['apikey'] and 'Enter OMDb API Key' not in data['omdb']['apikey'] else '' }}"
value="{{ data['omdb']['apikey'] | string if data['omdb']['apikey'] and 'Enter OMDb API Key' not in data['omdb']['apikey'] | string else '' }}"
aria-describedby="omdb_apikey_text">
<button class="btn btn-outline-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
2 changes: 1 addition & 1 deletion templates/060-mdblist.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="password" class="form-control" id="mdblist_apikey" name="mdblist_apikey"
value="{{ data['mdblist']['apikey'] if data['mdblist']['apikey'] and 'Enter MDBList API Key' not in data['mdblist']['apikey'] else '' }}" title="MDBList API Key"
value="{{ data['mdblist']['apikey'] | string if data['mdblist']['apikey'] and 'Enter MDBList API Key' not in data['mdblist']['apikey'] | string else '' }}" title="MDBList API Key"
aria-label="MDBList API Key">
<button class="btn btn-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
2 changes: 1 addition & 1 deletion templates/070-notifiarr.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="password" class="form-control" id="notifiarr_apikey" name="notifiarr_apikey"
value="{{ data['notifiarr']['apikey'] if data['notifiarr']['apikey'] and 'Enter Notifiarr API Key' not in data['notifiarr']['apikey'] else '' }}" title="Notifiarr API Key"
value="{{ data['notifiarr']['apikey'] | string if data['notifiarr']['apikey'] and 'Enter Notifiarr API Key' not in data['notifiarr']['apikey'] | string else '' }}" title="Notifiarr API Key"
aria-describedby="notifiarr_apikey_text">
<button class="btn btn-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
4 changes: 2 additions & 2 deletions templates/080-gotify.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="text" class="form-control" id="gotify_url" name="gotify_url"
value="{{ data['gotify']['url'] if data['gotify']['url'] and 'http://192.168.1.12:80' not in data['gotify']['url'] else '' }}"
value="{{ data['gotify']['url'] | string if data['gotify']['url'] and 'http://192.168.1.12:80' not in data['gotify']['url'] | string else '' }}"
title="Gotify URL" aria-describedby="gotify_url_text">
</div>

Expand All @@ -23,7 +23,7 @@
</span>
</span>
<input type="password" class="form-control" id="gotify_token" name="gotify_token"
value="{{ data['gotify']['token'] if data['gotify']['token'] and 'Enter Gotify Token' not in data['gotify']['token'] else '' }}"
value="{{ data['gotify']['token'] | string if data['gotify']['token'] and 'Enter Gotify Token' not in data['gotify']['token'] | string else '' }}"
title="Gotify API Key" aria-describedby="gotify_token_text">
<button class="btn btn-secondary" id="toggleTokenVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
6 changes: 3 additions & 3 deletions templates/085-ntfy.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="text" class="form-control" id="ntfy_url" name="ntfy_url"
value="{{ data['ntfy']['url'] if data['ntfy']['url'] and 'http://192.168.1.12:80' not in data['ntfy']['url'] else '' }}"
value="{{ data['ntfy']['url'] | string if data['ntfy']['url'] and 'http://192.168.1.12:80' not in data['ntfy']['url'] | string else '' }}"
title="Enter your ntfy server URL" aria-describedby="ntfy_url_text">
</div>

Expand All @@ -23,7 +23,7 @@
</span>
</span>
<input type="password" class="form-control" id="ntfy_token" name="ntfy_token"
value="{{ data['ntfy']['token'] if data['ntfy']['token'] and 'Enter ntfy Access Token' not in data['ntfy']['token'] else '' }}"
value="{{ data['ntfy']['token'] | string if data['ntfy']['token'] and 'Enter ntfy Access Token' not in data['ntfy']['token'] | string else '' }}"
title="ntfy API Key" aria-describedby="ntfy_token_text">
<button class="btn btn-secondary" id="toggleTokenVisibility" type="button">
<i class="fas fa-eye"></i>
Expand All @@ -43,7 +43,7 @@
</span>
</span>
<input type="text" class="form-control" id="ntfy_topic" name="ntfy_topic"
value="{{ data['ntfy']['topic'] if data['ntfy']['topic'] and 'Enter ntfy Topic' not in data['ntfy']['topic'] else '' }}"
value="{{ data['ntfy']['topic'] | string if data['ntfy']['topic'] and 'Enter ntfy Topic' not in data['ntfy']['topic'] | string else '' }}"
title="Enter your ntfy topic" aria-describedby="ntfy_topic_text">
</div>

Expand Down
6 changes: 3 additions & 3 deletions templates/100-anidb.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="text" class="form-control" id="anidb_client" name="anidb_client"
value="{{ data['anidb']['client'] if data['anidb']['client'] and 'Enter AniDB Client' not in data['anidb']['client'] else '' }}"
value="{{ data['anidb']['client'] | string if data['anidb']['client'] and 'Enter AniDB Client' not in data['anidb']['client'] | string else '' }}"
aria-describedby="anidb_client_text">
</div>

Expand All @@ -36,7 +36,7 @@
</span>
</span>
<input type="text" class="form-control" id="anidb_username" name="anidb_username"
value="{{ data['anidb']['username'] if data['anidb']['username'] and 'Enter AniDB Username' not in data['anidb']['username'] else '' }}"
value="{{ data['anidb']['username'] | string if data['anidb']['username'] and 'Enter AniDB Username' not in data['anidb']['username'] | string else '' }}"
aria-describedby="anidb_username_text">
</div>

Expand All @@ -49,7 +49,7 @@
</span>
</span>
<input type="password" class="form-control" id="anidb_password" name="anidb_password"
value="{{ data['anidb']['password'] if data['anidb']['password'] and 'Enter AniDB Password' not in data['anidb']['password'] else '' }}"
value="{{ data['anidb']['password'] | string if data['anidb']['password'] and 'Enter AniDB Password' not in data['anidb']['password'] | string else '' }}"
aria-describedby="anidb_password_text">
<button class="btn btn-outline-secondary" id="togglePasswordVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
4 changes: 2 additions & 2 deletions templates/110-radarr.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="text" class="form-control" id="radarr_url" name="radarr_url"
value="{{ data['radarr']['url'] if data['radarr']['url'] and 'http://192.168.1.12:7878' not in data['radarr']['url'] else '' }}"
value="{{ data['radarr']['url'] | string if data['radarr']['url'] and 'http://192.168.1.12:7878' not in data['radarr']['url'] | string else '' }}"
aria-describedby="radarr_url_text">
</div>

Expand All @@ -23,7 +23,7 @@
</span>
</span>
<input type="password" class="form-control" id="radarr_token" name="radarr_token"
value="{{ data['radarr']['token'] if data['radarr']['token'] and 'Enter Radarr API Key' not in data['radarr']['token'] else '' }}"
value="{{ data['radarr']['token'] | string if data['radarr']['token'] and 'Enter Radarr API Key' not in data['radarr']['token'] | string else '' }}"
aria-describedby="radarr_token_text">
<button class="btn btn-outline-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
4 changes: 2 additions & 2 deletions templates/120-sonarr.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="text" class="form-control" id="sonarr_url" name="sonarr_url"
value="{{ data['sonarr']['url'] if data['sonarr']['url'] and 'http://192.168.1.12:8989' not in data['sonarr']['url'] else '' }}"
value="{{ data['sonarr']['url'] | string if data['sonarr']['url'] and 'http://192.168.1.12:8989' not in data['sonarr']['url'] | string else '' }}"
aria-describedby="sonarr_url_text">
</div>
<div class="input-group mb-2">
Expand All @@ -22,7 +22,7 @@
</span>
</span>
<input type="password" class="form-control" id="sonarr_token" name="sonarr_token"
value="{{ data['sonarr']['token'] if data['sonarr']['token'] and 'Enter Sonarr API Key' not in data['sonarr']['token'] else '' }}"
value="{{ data['sonarr']['token'] | string if data['sonarr']['token'] and 'Enter Sonarr API Key' not in data['sonarr']['token'] | string else '' }}"
aria-describedby="sonarr_token_text">
<button class="btn btn-outline-secondary" id="toggleApikeyVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
4 changes: 2 additions & 2 deletions templates/130-trakt.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="text" class="form-control" id="trakt_client_id" name="trakt_client_id"
value="{{ data['trakt']['client_id'] if data['trakt']['client_id'] and 'Enter Trakt Client ID' not in data['trakt']['client_id'] else '' }}"
value="{{ data['trakt']['client_id'] | string if data['trakt']['client_id'] and 'Enter Trakt Client ID' not in data['trakt']['client_id'] | string else '' }}"
aria-describedby="trakt_client_id_text" oninput="updateTraktURL(this)">
</div>
<div class="input-group mb-2">
Expand All @@ -22,7 +22,7 @@
</span>
</span>
<input type="password" class="form-control" id="trakt_client_secret" name="trakt_client_secret"
value="{{ data['trakt']['client_secret'] if data['trakt']['client_secret'] and 'Enter Trakt Client Secret' not in data['trakt']['client_secret'] else '' }}"
value="{{ data['trakt']['client_secret'] | string if data['trakt']['client_secret'] and 'Enter Trakt Client Secret' not in data['trakt']['client_secret'] | string else '' }}"
title="Client Secret" aria-label="Client Secret" oninput="updateTraktURL(this)" aria-describedby="trakt_client_secret_text">
<button class="btn btn-outline-secondary" id="toggleClientSecretVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
4 changes: 2 additions & 2 deletions templates/140-mal.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</span>
</span>
<input type="text" class="form-control" id="mal_client_id" name="mal_client_id"
value="{{ data['mal']['client_id'] if data['mal']['client_id'] and 'Enter MyAnimeList Client ID' not in data['mal']['client_id'] else '' }}"
value="{{ data['mal']['client_id'] | string if data['mal']['client_id'] and 'Enter MyAnimeList Client ID' not in data['mal']['client_id'] | string else '' }}"
oninput="updateMALTargetURL(this)" aria-describedby="mal_client_id_text">
</div>
<div class="input-group mb-2">
Expand All @@ -25,7 +25,7 @@
</span>
</span>
<input type="password" class="form-control" id="mal_client_secret" name="mal_client_secret"
value="{{ data['mal']['client_secret'] if data['mal']['client_secret'] and 'Enter MyAnimeList Client Secret' not in data['mal']['client_secret'] else '' }}"
value="{{ data['mal']['client_secret'] | string if data['mal']['client_secret'] and 'Enter MyAnimeList Client Secret' not in data['mal']['client_secret'] | string else '' }}"
title="Client Secret" aria-label="Client Secret" oninput="updateMALTargetURL(this)" aria-describedby="mal_client_secret_text">
<button class="btn btn-outline-secondary" id="toggleClientSecretVisibility" type="button">
<i class="fas fa-eye"></i>
Expand Down
Loading