forked from midou/invidious
reword error messages
This commit is contained in:
parent
ca4c2115ee
commit
260bab598e
@ -472,5 +472,5 @@
|
|||||||
"crash_page_read_the_faq": "read the <a href=\"`x`\">Frequently Asked Questions (FAQ)</a>",
|
"crash_page_read_the_faq": "read the <a href=\"`x`\">Frequently Asked Questions (FAQ)</a>",
|
||||||
"crash_page_search_issue": "searched for <a href=\"`x`\">existing issues on GitHub</a>",
|
"crash_page_search_issue": "searched for <a href=\"`x`\">existing issues on GitHub</a>",
|
||||||
"crash_page_report_issue": "If none of the above helped, please <a href=\"`x`\">open a new issue on GitHub</a> (preferably in English) and include the following text in your message (do NOT translate that text):",
|
"crash_page_report_issue": "If none of the above helped, please <a href=\"`x`\">open a new issue on GitHub</a> (preferably in English) and include the following text in your message (do NOT translate that text):",
|
||||||
"video_not_exist_in_playlist": "The video requested doesn't exist in the playlist. Click <a href=\"`x`\">here</a> for the playlist home page."
|
"error_video_not_in_playlist": "The requested video doesn't exist in this playlist. <a href=\"`x`\">Click here for the playlist home page.</a>"
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@ module Invidious::Routes::Embed
|
|||||||
videos = get_playlist_videos(playlist, offset: offset)
|
videos = get_playlist_videos(playlist, offset: offset)
|
||||||
if videos.empty?
|
if videos.empty?
|
||||||
url = "/playlist?list=#{plid}"
|
url = "/playlist?list=#{plid}"
|
||||||
raise NotFoundException.new(translate(locale, "video_not_exist_in_playlist", url))
|
raise NotFoundException.new(translate(locale, "error_video_not_in_playlist", url))
|
||||||
end
|
end
|
||||||
rescue ex : NotFoundException
|
rescue ex : NotFoundException
|
||||||
return error_template(404, ex)
|
return error_template(404, ex)
|
||||||
@ -70,7 +70,7 @@ module Invidious::Routes::Embed
|
|||||||
videos = get_playlist_videos(playlist, offset: offset)
|
videos = get_playlist_videos(playlist, offset: offset)
|
||||||
if videos.empty?
|
if videos.empty?
|
||||||
url = "/playlist?list=#{plid}"
|
url = "/playlist?list=#{plid}"
|
||||||
raise NotFoundException.new(translate(locale, "video_not_exist_in_playlist", url))
|
raise NotFoundException.new(translate(locale, "error_video_not_in_playlist", url))
|
||||||
end
|
end
|
||||||
rescue ex : NotFoundException
|
rescue ex : NotFoundException
|
||||||
return error_template(404, ex)
|
return error_template(404, ex)
|
||||||
|
Loading…
Reference in New Issue
Block a user