Skip to content

Commit

Permalink
Merge branch 'cover_encodes_032024_1' into RFTW
Browse files Browse the repository at this point in the history
  • Loading branch information
theRealKLH committed Feb 14, 2024
2 parents 3ddd735 + 0a45edd commit a6bb070
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 7 deletions.
12 changes: 6 additions & 6 deletions ui/src/views/scenes/Details.vue
Original file line number Diff line number Diff line change
Expand Up @@ -782,12 +782,12 @@ watch:{
return u
}
try {
if (u.startsWith('http') || u.startsWith('https')) {
if (strpos(u, "%") !== false) {
return '/img/' + size + '/' + decodeURI(u)
}
return '/img/' + size + '/' + encodeURI(u)
} else {
if (u.startsWith('http')) {
if (u.search("%") == -1) {
return '/img/' + size + '/' + encodeURI(u)
} else {
return '/img/' + size + '/' + encodeURI(decodeURI(u))
}
return u
}
} catch {
Expand Down
9 changes: 8 additions & 1 deletion ui/src/views/scenes/SceneCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,14 @@ export default {
},
methods: {
getImageURL (u) {
return '/img/700x/' + u
if (u.startsWith('http') == false) {
return u
}
if (u.search("%") == -1) {
return '/img/700x/' + encodeURI(u)
} else {
return '/img/700x/' + encodeURI(decodeURI(u))
}
},
showDetails (scene) {
// reRead is required when the SceneCard is clicked from the ActorDetails
Expand Down

0 comments on commit a6bb070

Please sign in to comment.