Merge branch 'master' into feature/login-redirect

pull/3556/head
Brahim Hadriche 2 years ago
commit 0e22a0c21a

@ -43,7 +43,7 @@ RUN if [[ "${release}" == 1 && "${disable_quic}" == 1 ]] ; then \
FROM alpine:3.16 FROM alpine:3.16
RUN apk add --no-cache librsvg ttf-opensans RUN apk add --no-cache librsvg ttf-opensans tini
WORKDIR /invidious WORKDIR /invidious
RUN addgroup -g 1000 -S invidious && \ RUN addgroup -g 1000 -S invidious && \
adduser -u 1000 -S invidious -G invidious adduser -u 1000 -S invidious -G invidious
@ -58,4 +58,5 @@ RUN chmod o+rX -R ./assets ./config ./locales
EXPOSE 3000 EXPOSE 3000
USER invidious USER invidious
ENTRYPOINT ["/sbin/tini", "--"]
CMD [ "/invidious/invidious" ] CMD [ "/invidious/invidious" ]

@ -42,7 +42,7 @@ RUN if [[ "${release}" == 1 && "${disable_quic}" == 1 ]] ; then \
fi fi
FROM alpine:3.16 FROM alpine:3.16
RUN apk add --no-cache librsvg ttf-opensans RUN apk add --no-cache librsvg ttf-opensans tini
WORKDIR /invidious WORKDIR /invidious
RUN addgroup -g 1000 -S invidious && \ RUN addgroup -g 1000 -S invidious && \
adduser -u 1000 -S invidious -G invidious adduser -u 1000 -S invidious -G invidious
@ -57,4 +57,5 @@ RUN chmod o+rX -R ./assets ./config ./locales
EXPOSE 3000 EXPOSE 3000
USER invidious USER invidious
ENTRYPOINT ["/sbin/tini", "--"]
CMD [ "/invidious/invidious" ] CMD [ "/invidious/invidious" ]

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "`x` أعجب بهذا", "`x` marked it with a ❤": "`x` أعجب بهذا",
"Audio mode": "الوضع الصوتي", "Audio mode": "الوضع الصوتي",
"Video mode": "وضع الفيديو", "Video mode": "وضع الفيديو",
"Videos": "الفيديوهات", "channel_tab_videos_label": "الفيديوهات",
"Playlists": "قوائم التشغيل", "Playlists": "قوائم التشغيل",
"Community": "المجتمع", "channel_tab_community_label": "المجتمع",
"search_filters_sort_option_relevance": "ملائمة", "search_filters_sort_option_relevance": "ملائمة",
"search_filters_sort_option_rating": "تقييم", "search_filters_sort_option_rating": "تقييم",
"search_filters_sort_option_date": "التاريخ", "search_filters_sort_option_date": "التاريخ",

@ -51,7 +51,7 @@
"Movies": "Películes", "Movies": "Películes",
"Download": "Descarrega", "Download": "Descarrega",
"Download as: ": "Descarrega com: ", "Download as: ": "Descarrega com: ",
"Videos": "Vídeos", "channel_tab_videos_label": "Vídeos",
"search_filters_type_label": "Tipus", "search_filters_type_label": "Tipus",
"search_filters_duration_label": "Duració", "search_filters_duration_label": "Duració",
"search_filters_sort_label": "Ordena per", "search_filters_sort_label": "Ordena per",

@ -260,8 +260,8 @@
"`x` marked it with a ❤": "`x` to označil(a) se ❤", "`x` marked it with a ❤": "`x` to označil(a) se ❤",
"Audio mode": "Audiový režim", "Audio mode": "Audiový režim",
"Video mode": "Videový režim", "Video mode": "Videový režim",
"Videos": "Videa", "channel_tab_videos_label": "Videa",
"Community": "Komunita", "channel_tab_community_label": "Komunita",
"search_filters_sort_option_rating": "Hodnocení", "search_filters_sort_option_rating": "Hodnocení",
"search_filters_sort_option_date": "Datum nahrání", "search_filters_sort_option_date": "Datum nahrání",
"search_filters_sort_option_views": "Počet zhlédnutí", "search_filters_sort_option_views": "Počet zhlédnutí",

@ -187,7 +187,7 @@
"Esperanto": "Esperanto", "Esperanto": "Esperanto",
"Czech": "Tjekkisk", "Czech": "Tjekkisk",
"Danish": "Dansk", "Danish": "Dansk",
"Community": "Samfund", "channel_tab_community_label": "Samfund",
"Afrikaans": "Afrikansk", "Afrikaans": "Afrikansk",
"Portuguese": "Portugisisk", "Portuguese": "Portugisisk",
"Ukrainian": "Ukrainsk", "Ukrainian": "Ukrainsk",
@ -267,7 +267,7 @@
"search_filters_sort_option_rating": "Bedømmelse", "search_filters_sort_option_rating": "Bedømmelse",
"Yoruba": "Yoruba", "Yoruba": "Yoruba",
"Erroneous token": "Fejlagtig token", "Erroneous token": "Fejlagtig token",
"Videos": "Videoer", "channel_tab_videos_label": "Videoer",
"search_filters_type_option_show": "Vis", "search_filters_type_option_show": "Vis",
"Luxembourgish": "Luxemboursk", "Luxembourgish": "Luxemboursk",
"Vietnamese": "Vietnamesisk", "Vietnamese": "Vietnamesisk",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "`x` markierte es mit einem ❤", "`x` marked it with a ❤": "`x` markierte es mit einem ❤",
"Audio mode": "Audiomodus", "Audio mode": "Audiomodus",
"Video mode": "Videomodus", "Video mode": "Videomodus",
"Videos": "Videos", "channel_tab_videos_label": "Videos",
"Playlists": "Wiedergabelisten", "Playlists": "Wiedergabelisten",
"Community": "Gemeinschaft", "channel_tab_community_label": "Gemeinschaft",
"search_filters_sort_option_relevance": "Relevanz", "search_filters_sort_option_relevance": "Relevanz",
"search_filters_sort_option_rating": "Bewertung", "search_filters_sort_option_rating": "Bewertung",
"search_filters_sort_option_date": "Datum", "search_filters_sort_option_date": "Datum",

@ -315,9 +315,9 @@
"`x` marked it with a ❤": "Ο χρηστης `x` έβαλε ❤", "`x` marked it with a ❤": "Ο χρηστης `x` έβαλε ❤",
"Audio mode": "Λειτουργία ήχου", "Audio mode": "Λειτουργία ήχου",
"Video mode": "Λειτουργία βίντεο", "Video mode": "Λειτουργία βίντεο",
"Videos": "Βίντεο", "channel_tab_videos_label": "Βίντεο",
"Playlists": "Λίστες Αναπαραγωγής", "Playlists": "Λίστες Αναπαραγωγής",
"Community": "Κοινότητα", "channel_tab_community_label": "Κοινότητα",
"Current version: ": "Τρέχουσα έκδοση: ", "Current version: ": "Τρέχουσα έκδοση: ",
"generic_playlists_count": "{{count}} λίστα αναπαραγωγής", "generic_playlists_count": "{{count}} λίστα αναπαραγωγής",
"generic_playlists_count_plural": "{{count}} λίστες αναπαραγωγής", "generic_playlists_count_plural": "{{count}} λίστες αναπαραγωγής",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "`x` markis ĝin per ❤", "`x` marked it with a ❤": "`x` markis ĝin per ❤",
"Audio mode": "Aŭda reĝimo", "Audio mode": "Aŭda reĝimo",
"Video mode": "Videa reĝimo", "Video mode": "Videa reĝimo",
"Videos": "Filmetoj", "channel_tab_videos_label": "Filmetoj",
"Playlists": "Ludlistoj", "Playlists": "Ludlistoj",
"Community": "Komunumo", "channel_tab_community_label": "Komunumo",
"search_filters_sort_option_relevance": "rilateco", "search_filters_sort_option_relevance": "rilateco",
"search_filters_sort_option_rating": "takso", "search_filters_sort_option_rating": "takso",
"search_filters_sort_option_date": "dato", "search_filters_sort_option_date": "dato",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "`x` lo ha marcado con un ❤", "`x` marked it with a ❤": "`x` lo ha marcado con un ❤",
"Audio mode": "Modo de audio", "Audio mode": "Modo de audio",
"Video mode": "Modo de vídeo", "Video mode": "Modo de vídeo",
"Videos": "Vídeos", "channel_tab_videos_label": "Vídeos",
"Playlists": "Listas de reproducción", "Playlists": "Listas de reproducción",
"Community": "Comunidad", "channel_tab_community_label": "Comunidad",
"search_filters_sort_option_relevance": "relevancia", "search_filters_sort_option_relevance": "relevancia",
"search_filters_sort_option_rating": "valoración", "search_filters_sort_option_rating": "valoración",
"search_filters_sort_option_date": "fecha", "search_filters_sort_option_date": "fecha",

@ -296,8 +296,8 @@
"Corsican": "Korsika", "Corsican": "Korsika",
"Javanese": "Jaava", "Javanese": "Jaava",
"Lithuanian": "Leedu", "Lithuanian": "Leedu",
"Videos": "Videod", "channel_tab_videos_label": "Videod",
"Community": "Kogukond", "channel_tab_community_label": "Kogukond",
"CAPTCHA is a required field": "CAPTCHA on kohustuslik väli", "CAPTCHA is a required field": "CAPTCHA on kohustuslik väli",
"comments_points_count": "{{count}} punkt", "comments_points_count": "{{count}} punkt",
"comments_points_count_plural": "{{count}} punkti", "comments_points_count_plural": "{{count}} punkti",

@ -341,9 +341,9 @@
"`x` marked it with a ❤": "`x` نشان گذاری شده با یک ❤", "`x` marked it with a ❤": "`x` نشان گذاری شده با یک ❤",
"Audio mode": "حالت صدا", "Audio mode": "حالت صدا",
"Video mode": "حالت ویدیو", "Video mode": "حالت ویدیو",
"Videos": "ویدیو ها", "channel_tab_videos_label": "ویدیو ها",
"Playlists": "سیاهه‌های پخش", "Playlists": "سیاهه‌های پخش",
"Community": "اجتماع", "channel_tab_community_label": "اجتماع",
"search_filters_sort_option_relevance": "مرتبط بودن", "search_filters_sort_option_relevance": "مرتبط بودن",
"search_filters_sort_option_rating": "امتیاز", "search_filters_sort_option_rating": "امتیاز",
"search_filters_sort_option_date": "تاریخ بارگذاری", "search_filters_sort_option_date": "تاریخ بارگذاری",

@ -324,9 +324,9 @@
"`x` marked it with a ❤": "`x` merkkasi ❤:llä", "`x` marked it with a ❤": "`x` merkkasi ❤:llä",
"Audio mode": "Äänitila", "Audio mode": "Äänitila",
"Video mode": "Videotila", "Video mode": "Videotila",
"Videos": "Videot", "channel_tab_videos_label": "Videot",
"Playlists": "Soittolistat", "Playlists": "Soittolistat",
"Community": "Yhteisö", "channel_tab_community_label": "Yhteisö",
"search_filters_sort_option_relevance": "Osuvuus", "search_filters_sort_option_relevance": "Osuvuus",
"search_filters_sort_option_rating": "Arvostelu", "search_filters_sort_option_rating": "Arvostelu",
"search_filters_sort_option_date": "Latauspäivämäärä", "search_filters_sort_option_date": "Latauspäivämäärä",

@ -358,9 +358,9 @@
"`x` marked it with a ❤": "`x` l'a marqué d'un ❤", "`x` marked it with a ❤": "`x` l'a marqué d'un ❤",
"Audio mode": "Mode audio", "Audio mode": "Mode audio",
"Video mode": "Mode vidéo", "Video mode": "Mode vidéo",
"Videos": "Vidéos", "channel_tab_videos_label": "Vidéos",
"Playlists": "Listes de lecture", "Playlists": "Listes de lecture",
"Community": "Communauté", "channel_tab_community_label": "Communauté",
"search_filters_sort_option_relevance": "Pertinence", "search_filters_sort_option_relevance": "Pertinence",
"search_filters_sort_option_rating": "Notation", "search_filters_sort_option_rating": "Notation",
"search_filters_sort_option_date": "Date d'ajout", "search_filters_sort_option_date": "Date d'ajout",

@ -271,9 +271,9 @@
"`x` marked it with a ❤": "סומנה ב־❤ על ידי `x`", "`x` marked it with a ❤": "סומנה ב־❤ על ידי `x`",
"Audio mode": "Audio mode", "Audio mode": "Audio mode",
"Video mode": "Video mode", "Video mode": "Video mode",
"Videos": "סרטונים", "channel_tab_videos_label": "סרטונים",
"Playlists": "פלייליסטים", "Playlists": "פלייליסטים",
"Community": "קהילה", "channel_tab_community_label": "קהילה",
"search_filters_sort_option_relevance": "רלוונטיות", "search_filters_sort_option_relevance": "רלוונטיות",
"search_filters_sort_option_rating": "דירוג", "search_filters_sort_option_rating": "דירוג",
"search_filters_sort_option_date": "תאריך העלאה", "search_filters_sort_option_date": "תאריך העלאה",

@ -401,12 +401,12 @@
"(edited)": "(संपादित)", "(edited)": "(संपादित)",
"YouTube comment permalink": "YouTube पर टिप्पणी की स्थायी कड़ी", "YouTube comment permalink": "YouTube पर टिप्पणी की स्थायी कड़ी",
"permalink": "स्थायी कड़ी", "permalink": "स्थायी कड़ी",
"Videos": "वीडियो", "channel_tab_videos_label": "वीडियो",
"`x` marked it with a ❤": "`x` ने इसे एक ❤ से चिह्नित किया", "`x` marked it with a ❤": "`x` ने इसे एक ❤ से चिह्नित किया",
"Audio mode": "ऑडियो मोड", "Audio mode": "ऑडियो मोड",
"Playlists": "प्लेलिस्ट्स", "Playlists": "प्लेलिस्ट्स",
"Video mode": "वीडियो मोड", "Video mode": "वीडियो मोड",
"Community": "समुदाय", "channel_tab_community_label": "समुदाय",
"search_filters_title": "फ़िल्टर", "search_filters_title": "फ़िल्टर",
"search_filters_date_label": "अपलोड करने का समय", "search_filters_date_label": "अपलोड करने का समय",
"search_filters_date_option_none": "कोई भी समय", "search_filters_date_option_none": "कोई भी समय",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "Označeno sa ❤ od `x`", "`x` marked it with a ❤": "Označeno sa ❤ od `x`",
"Audio mode": "Audio modus", "Audio mode": "Audio modus",
"Video mode": "Videomodus", "Video mode": "Videomodus",
"Videos": "Videa", "channel_tab_videos_label": "Videa",
"Playlists": "Zbirke", "Playlists": "Zbirke",
"Community": "Zajednica", "channel_tab_community_label": "Zajednica",
"search_filters_sort_option_relevance": "Značaj", "search_filters_sort_option_relevance": "Značaj",
"search_filters_sort_option_rating": "Ocjena", "search_filters_sort_option_rating": "Ocjena",
"search_filters_sort_option_date": "Datum prijenosa", "search_filters_sort_option_date": "Datum prijenosa",

@ -348,9 +348,9 @@
"`x` marked it with a ❤": "`x` ❤jelet adott a hozzászóláshoz", "`x` marked it with a ❤": "`x` ❤jelet adott a hozzászóláshoz",
"Audio mode": "Csak hanggal", "Audio mode": "Csak hanggal",
"Video mode": "Hanggal és képpel", "Video mode": "Hanggal és képpel",
"Videos": "Videói", "channel_tab_videos_label": "Videói",
"Playlists": "Lejátszási listái", "Playlists": "Lejátszási listái",
"Community": "Közösség", "channel_tab_community_label": "Közösség",
"Current version: ": "Jelenlegi verzió: ", "Current version: ": "Jelenlegi verzió: ",
"preferences_quality_option_medium": "Közepes", "preferences_quality_option_medium": "Közepes",
"preferences_quality_dash_option_auto": "Automatikus", "preferences_quality_dash_option_auto": "Automatikus",

@ -341,9 +341,9 @@
"`x` marked it with a ❤": "`x` telah ditandai dengan ❤", "`x` marked it with a ❤": "`x` telah ditandai dengan ❤",
"Audio mode": "Mode audio", "Audio mode": "Mode audio",
"Video mode": "Mode video", "Video mode": "Mode video",
"Videos": "Video", "channel_tab_videos_label": "Video",
"Playlists": "Daftar putar", "Playlists": "Daftar putar",
"Community": "Komunitas", "channel_tab_community_label": "Komunitas",
"search_filters_sort_option_relevance": "Relevansi", "search_filters_sort_option_relevance": "Relevansi",
"search_filters_sort_option_rating": "Penilaian", "search_filters_sort_option_rating": "Penilaian",
"search_filters_sort_option_date": "Tanggal Unggah", "search_filters_sort_option_date": "Tanggal Unggah",

@ -315,9 +315,9 @@
"`x` marked it with a ❤": "`x` merkti það með ❤", "`x` marked it with a ❤": "`x` merkti það með ❤",
"Audio mode": "Hljóð ham", "Audio mode": "Hljóð ham",
"Video mode": "Myndband ham", "Video mode": "Myndband ham",
"Videos": "Myndbönd", "channel_tab_videos_label": "Myndbönd",
"Playlists": "Spilunarlistar", "Playlists": "Spilunarlistar",
"Community": "Samfélag", "channel_tab_community_label": "Samfélag",
"Current version: ": "Núverandi útgáfa: ", "Current version: ": "Núverandi útgáfa: ",
"preferences_watch_history_label": "Virkja áhorfssögu: " "preferences_watch_history_label": "Virkja áhorfssögu: "
} }

@ -344,9 +344,9 @@
"`x` marked it with a ❤": "`x` l'ha contrassegnato con un ❤", "`x` marked it with a ❤": "`x` l'ha contrassegnato con un ❤",
"Audio mode": "Modalità audio", "Audio mode": "Modalità audio",
"Video mode": "Modalità video", "Video mode": "Modalità video",
"Videos": "Video", "channel_tab_videos_label": "Video",
"Playlists": "Playlist", "Playlists": "Playlist",
"Community": "Comunità", "channel_tab_community_label": "Comunità",
"search_filters_sort_option_relevance": "Pertinenza", "search_filters_sort_option_relevance": "Pertinenza",
"search_filters_sort_option_rating": "Valutazione", "search_filters_sort_option_rating": "Valutazione",
"search_filters_sort_option_date": "Data di caricamento", "search_filters_sort_option_date": "Data di caricamento",

@ -341,9 +341,9 @@
"`x` marked it with a ❤": "`x` が❤を込めてマークしました", "`x` marked it with a ❤": "`x` が❤を込めてマークしました",
"Audio mode": "オーディオモード", "Audio mode": "オーディオモード",
"Video mode": "ビデオモード", "Video mode": "ビデオモード",
"Videos": "動画", "channel_tab_videos_label": "動画",
"Playlists": "プレイリスト", "Playlists": "プレイリスト",
"Community": "コミュニティ", "channel_tab_community_label": "コミュニティ",
"search_filters_sort_option_relevance": "関連", "search_filters_sort_option_relevance": "関連",
"search_filters_sort_option_rating": "評価", "search_filters_sort_option_rating": "評価",
"search_filters_sort_option_date": "時刻", "search_filters_sort_option_date": "時刻",

@ -2,7 +2,7 @@
"preferences_sort_label": "동영상 정렬 기준: ", "preferences_sort_label": "동영상 정렬 기준: ",
"preferences_max_results_label": "피드에 표시된 동영상 수: ", "preferences_max_results_label": "피드에 표시된 동영상 수: ",
"Redirect homepage to feed: ": "피드로 홈페이지 리디렉션: ", "Redirect homepage to feed: ": "피드로 홈페이지 리디렉션: ",
"preferences_annotations_subscribed_label": "구독한 채널에 기본적으로 특수효과를 표시하시겠습니까? ", "preferences_annotations_subscribed_label": "구독한 채널에 기본으로 주석 표시: ",
"preferences_category_subscription": "구독 설정", "preferences_category_subscription": "구독 설정",
"preferences_automatic_instance_redirect_label": "자동 인스턴스 리디렉션 (redirect.invidious.io로 대체): ", "preferences_automatic_instance_redirect_label": "자동 인스턴스 리디렉션 (redirect.invidious.io로 대체): ",
"preferences_thin_mode_label": "단순 모드: ", "preferences_thin_mode_label": "단순 모드: ",
@ -26,7 +26,7 @@
"preferences_speed_label": "기본 속도: ", "preferences_speed_label": "기본 속도: ",
"preferences_local_label": "비디오를 프록시: ", "preferences_local_label": "비디오를 프록시: ",
"preferences_listen_label": "라디오 모드: ", "preferences_listen_label": "라디오 모드: ",
"preferences_continue_autoplay_label": "다음 동영상 자동재생 ", "preferences_continue_autoplay_label": "다음 동영상 자동재생: ",
"preferences_continue_label": "다음 동영상으로 이동: ", "preferences_continue_label": "다음 동영상으로 이동: ",
"preferences_autoplay_label": "자동재생: ", "preferences_autoplay_label": "자동재생: ",
"preferences_video_loop_label": "항상 반복: ", "preferences_video_loop_label": "항상 반복: ",
@ -37,8 +37,8 @@
"Register": "회원가입", "Register": "회원가입",
"Sign In": "로그인", "Sign In": "로그인",
"preferences_category_misc": "기타 설정", "preferences_category_misc": "기타 설정",
"Image CAPTCHA": "이미지 CAPTCHA", "Image CAPTCHA": "이미지 캡차",
"Text CAPTCHA": "텍스트 CAPTCHA", "Text CAPTCHA": "텍스트 캡차",
"Time (h:mm:ss):": "시각 (h:mm:ss):", "Time (h:mm:ss):": "시각 (h:mm:ss):",
"Password": "비밀번호", "Password": "비밀번호",
"User ID": "사용자 ID", "User ID": "사용자 ID",
@ -50,15 +50,15 @@
"An alternative front-end to YouTube": "유튜브의 프론트엔드 대안", "An alternative front-end to YouTube": "유튜브의 프론트엔드 대안",
"History": "역사", "History": "역사",
"Delete account?": "계정을 삭제 하시겠습니까?", "Delete account?": "계정을 삭제 하시겠습니까?",
"Export data as JSON": "데이터를 JSON으로 내보내기", "Export data as JSON": "JSON으로 데이터 내보내기",
"Export subscriptions as OPML (for NewPipe & FreeTube)": "구독을 OPML로 내보내기 (NewPipe 및 FreeTube 용)", "Export subscriptions as OPML (for NewPipe & FreeTube)": "OPML로 구독 내보내기 (뉴파이프 및 프리튜브)",
"Export subscriptions as OPML": "구독을 OPML로 내보내기", "Export subscriptions as OPML": "OPML로 구독 내보내기",
"Export": "내보내기", "Export": "내보내기",
"Import NewPipe data (.zip)": "NewPipe 데이터 가져오기 (.zip)", "Import NewPipe data (.zip)": "뉴파이프 데이터 가져오기 (.zip)",
"Import NewPipe subscriptions (.json)": "NewPipe 구독을 가져오기 (.json)", "Import NewPipe subscriptions (.json)": "뉴파이프 구독 가져오기 (.json)",
"Import FreeTube subscriptions (.db)": "FreeTube 구독 가져오기 (.db)", "Import FreeTube subscriptions (.db)": "프리튜브 구독 가져오기 (.db)",
"Import YouTube subscriptions": "유튜브 구독 가져오기", "Import YouTube subscriptions": "유튜브 구독 가져오기",
"Import Invidious data": "인비디어스 JSON 데이터 가져오기", "Import Invidious data": "인비디어스 데이터 가져오기 (.json)",
"Import": "가져오기", "Import": "가져오기",
"Import and Export Data": "데이터 가져오기 및 내보내기", "Import and Export Data": "데이터 가져오기 및 내보내기",
"No": "아니요", "No": "아니요",
@ -152,7 +152,7 @@
"Report statistics: ": "통계 보고: ", "Report statistics: ": "통계 보고: ",
"Registration enabled: ": "등록 활성화: ", "Registration enabled: ": "등록 활성화: ",
"Login enabled: ": "로그인 활성화: ", "Login enabled: ": "로그인 활성화: ",
"CAPTCHA enabled: ": "CAPTCHA 활성화: ", "CAPTCHA enabled: ": "캡차 활성화: ",
"Top enabled: ": "Top 활성화: ", "Top enabled: ": "Top 활성화: ",
"preferences_show_nick_label": "상단에 닉네임 표시: ", "preferences_show_nick_label": "상단에 닉네임 표시: ",
"preferences_feed_menu_label": "피드 메뉴: ", "preferences_feed_menu_label": "피드 메뉴: ",
@ -284,10 +284,10 @@
"Password cannot be empty": "비밀번호는 비워둘 수 없습니다", "Password cannot be empty": "비밀번호는 비워둘 수 없습니다",
"Please sign in using 'Log in with Google'": "'구글로 로그인'을 사용하여 로그인하세요", "Please sign in using 'Log in with Google'": "'구글로 로그인'을 사용하여 로그인하세요",
"Wrong username or password": "잘못된 사용자 이름 또는 비밀번호", "Wrong username or password": "잘못된 사용자 이름 또는 비밀번호",
"Password is a required field": "비밀번호는 필수 필드입니다", "Password is a required field": "비밀번호는 필수 입력란입니다",
"User ID is a required field": "사용자 ID는 필수 필드입니다", "User ID is a required field": "사용자 ID는 필수 입력란입니다",
"CAPTCHA is a required field": "CAPTCHA는 필수 필드입니다", "CAPTCHA is a required field": "캡차는 필수 입력란입니다",
"Erroneous CAPTCHA": "잘못된 CAPTCHA", "Erroneous CAPTCHA": "잘못된 캡차",
"Login failed. This may be because two-factor authentication is not turned on for your account.": "로그인 실패. 계정에 이중 인증이 설정되어 있지 않기 때문일 수 있습니다.", "Login failed. This may be because two-factor authentication is not turned on for your account.": "로그인 실패. 계정에 이중 인증이 설정되어 있지 않기 때문일 수 있습니다.",
"Blacklisted regions: ": "차단된 지역: ", "Blacklisted regions: ": "차단된 지역: ",
"Playlists": "재생목록", "Playlists": "재생목록",
@ -297,7 +297,7 @@
"Empty playlist": "재생목록 비어 있음", "Empty playlist": "재생목록 비어 있음",
"Show annotations": "주석 보이기", "Show annotations": "주석 보이기",
"Hide annotations": "주석 숨기기", "Hide annotations": "주석 숨기기",
"Switch Invidious Instance": "Invidious 인스턴스 변경", "Switch Invidious Instance": "인비디어스 인스턴스 변경",
"Spanish": "스페인어", "Spanish": "스페인어",
"Southern Sotho": "소토어", "Southern Sotho": "소토어",
"Somali": "소말리어", "Somali": "소말리어",
@ -347,8 +347,8 @@
"search_filters_sort_option_date": "업로드 날짜", "search_filters_sort_option_date": "업로드 날짜",
"search_filters_sort_option_rating": "평점", "search_filters_sort_option_rating": "평점",
"search_filters_sort_option_relevance": "관련성", "search_filters_sort_option_relevance": "관련성",
"Community": "커뮤니티", "channel_tab_community_label": "커뮤니티",
"Videos": "동영상", "channel_tab_videos_label": "동영상",
"Video mode": "비디오 모드", "Video mode": "비디오 모드",
"Audio mode": "오디오 모드", "Audio mode": "오디오 모드",
"permalink": "퍼머링크", "permalink": "퍼머링크",
@ -383,7 +383,7 @@
"adminprefs_modified_source_code_url_label": "수정된 소스 코드 저장소의 URL", "adminprefs_modified_source_code_url_label": "수정된 소스 코드 저장소의 URL",
"search_filters_title": "필터", "search_filters_title": "필터",
"preferences_quality_dash_option_4320p": "4320p", "preferences_quality_dash_option_4320p": "4320p",
"Popular enabled: ": "인기 급상승 활성화: ", "Popular enabled: ": "인기 활성화: ",
"Dutch (auto-generated)": "네덜란드어 (자동 생성됨)", "Dutch (auto-generated)": "네덜란드어 (자동 생성됨)",
"Chinese (Hong Kong)": "중국어 (홍콩)", "Chinese (Hong Kong)": "중국어 (홍콩)",
"Chinese (Taiwan)": "중국어 (대만)", "Chinese (Taiwan)": "중국어 (대만)",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "`x` pažymėjo tai su ❤", "`x` marked it with a ❤": "`x` pažymėjo tai su ❤",
"Audio mode": "Garso rėžimas", "Audio mode": "Garso rėžimas",
"Video mode": "Vaizdo rėžimas", "Video mode": "Vaizdo rėžimas",
"Videos": "Vaizdo įrašai", "channel_tab_videos_label": "Vaizdo įrašai",
"Playlists": "Grojaraiščiai", "Playlists": "Grojaraiščiai",
"Community": "Bendruomenė", "channel_tab_community_label": "Bendruomenė",
"search_filters_sort_option_relevance": "Aktualumas", "search_filters_sort_option_relevance": "Aktualumas",
"search_filters_sort_option_rating": "Reitingas", "search_filters_sort_option_rating": "Reitingas",
"search_filters_sort_option_date": "Įkėlimo data", "search_filters_sort_option_date": "Įkėlimo data",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "`x` levnet et ❤", "`x` marked it with a ❤": "`x` levnet et ❤",
"Audio mode": "Lydmodus", "Audio mode": "Lydmodus",
"Video mode": "Video-modus", "Video mode": "Video-modus",
"Videos": "Videoer", "channel_tab_videos_label": "Videoer",
"Playlists": "Spillelister", "Playlists": "Spillelister",
"Community": "Gemenskap", "channel_tab_community_label": "Gemenskap",
"search_filters_sort_option_relevance": "relevans", "search_filters_sort_option_relevance": "relevans",
"search_filters_sort_option_rating": "vurdering", "search_filters_sort_option_rating": "vurdering",
"search_filters_sort_option_date": "dato", "search_filters_sort_option_date": "dato",

@ -320,9 +320,9 @@
"`x` marked it with a ❤": "`x` heeft dit gemarkeerd met ❤", "`x` marked it with a ❤": "`x` heeft dit gemarkeerd met ❤",
"Audio mode": "Audiomodus", "Audio mode": "Audiomodus",
"Video mode": "Videomodus", "Video mode": "Videomodus",
"Videos": "Video's", "channel_tab_videos_label": "Video's",
"Playlists": "Afspeellijsten", "Playlists": "Afspeellijsten",
"Community": "Gemeenschap", "channel_tab_community_label": "Gemeenschap",
"search_filters_sort_option_relevance": "relevantie", "search_filters_sort_option_relevance": "relevantie",
"search_filters_sort_option_rating": "beoordeling", "search_filters_sort_option_rating": "beoordeling",
"search_filters_sort_option_date": "datum", "search_filters_sort_option_date": "datum",

@ -324,9 +324,9 @@
"`x` marked it with a ❤": "`x` oznaczonych ❤", "`x` marked it with a ❤": "`x` oznaczonych ❤",
"Audio mode": "Tryb audio", "Audio mode": "Tryb audio",
"Video mode": "Tryb wideo", "Video mode": "Tryb wideo",
"Videos": "Filmy", "channel_tab_videos_label": "Filmy",
"Playlists": "Playlisty", "Playlists": "Playlisty",
"Community": "Społeczność", "channel_tab_community_label": "Społeczność",
"search_filters_sort_option_relevance": "Trafność", "search_filters_sort_option_relevance": "Trafność",
"search_filters_sort_option_rating": "Ocena", "search_filters_sort_option_rating": "Ocena",
"search_filters_sort_option_date": "Data przesłania", "search_filters_sort_option_date": "Data przesłania",

@ -341,9 +341,9 @@
"`x` marked it with a ❤": "`x` foi marcado como ❤", "`x` marked it with a ❤": "`x` foi marcado como ❤",
"Audio mode": "Modo de áudio", "Audio mode": "Modo de áudio",
"Video mode": "Modo de vídeo", "Video mode": "Modo de vídeo",
"Videos": "Vídeos", "channel_tab_videos_label": "Vídeos",
"Playlists": "Listas de reprodução", "Playlists": "Listas de reprodução",
"Community": "Comunidade", "channel_tab_community_label": "Comunidade",
"search_filters_sort_option_relevance": "relevância", "search_filters_sort_option_relevance": "relevância",
"search_filters_sort_option_rating": "avaliação", "search_filters_sort_option_rating": "avaliação",
"search_filters_sort_option_date": "data", "search_filters_sort_option_date": "data",

@ -341,9 +341,9 @@
"`x` marked it with a ❤": "`x` foi marcado como ❤", "`x` marked it with a ❤": "`x` foi marcado como ❤",
"Audio mode": "Modo de áudio", "Audio mode": "Modo de áudio",
"Video mode": "Modo de vídeo", "Video mode": "Modo de vídeo",
"Videos": "Vídeos", "channel_tab_videos_label": "Vídeos",
"Playlists": "Listas de reprodução", "Playlists": "Listas de reprodução",
"Community": "Comunidade", "channel_tab_community_label": "Comunidade",
"search_filters_sort_option_relevance": "Relevância", "search_filters_sort_option_relevance": "Relevância",
"search_filters_sort_option_rating": "Avaliação", "search_filters_sort_option_rating": "Avaliação",
"search_filters_sort_option_date": "Data de envio", "search_filters_sort_option_date": "Data de envio",

@ -267,9 +267,9 @@
"Next page": "Próxima página", "Next page": "Próxima página",
"last": "últimos", "last": "últimos",
"Current version: ": "Versão atual: ", "Current version: ": "Versão atual: ",
"Community": "Comunidade", "channel_tab_community_label": "Comunidade",
"Playlists": "Listas de reprodução", "Playlists": "Listas de reprodução",
"Videos": "Vídeos", "channel_tab_videos_label": "Vídeos",
"Video mode": "Modo de vídeo", "Video mode": "Modo de vídeo",
"Audio mode": "Modo de áudio", "Audio mode": "Modo de áudio",
"`x` marked it with a ❤": "`x` foi marcado como ❤", "`x` marked it with a ❤": "`x` foi marcado como ❤",

@ -315,9 +315,9 @@
"`x` marked it with a ❤": "`x` l-a marcat cu o ❤", "`x` marked it with a ❤": "`x` l-a marcat cu o ❤",
"Audio mode": "Mod audio", "Audio mode": "Mod audio",
"Video mode": "Mod video", "Video mode": "Mod video",
"Videos": "Videoclipuri", "channel_tab_videos_label": "Videoclipuri",
"Playlists": "Liste de redare", "Playlists": "Liste de redare",
"Community": "Comunitate", "channel_tab_community_label": "Comunitate",
"Current version: ": "Versiunea actuală: ", "Current version: ": "Versiunea actuală: ",
"crash_page_read_the_faq": "citit lista <a href=\"`x`\">Întrebărilor Frecvente (FAQ)</a>", "crash_page_read_the_faq": "citit lista <a href=\"`x`\">Întrebărilor Frecvente (FAQ)</a>",
"generic_count_days_0": "{{count}} zi", "generic_count_days_0": "{{count}} zi",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "❤ от автора канала \"`x`\"", "`x` marked it with a ❤": "❤ от автора канала \"`x`\"",
"Audio mode": "Аудио режим", "Audio mode": "Аудио режим",
"Video mode": "Видео режим", "Video mode": "Видео режим",
"Videos": "Видео", "channel_tab_videos_label": "Видео",
"Playlists": "Плейлисты", "Playlists": "Плейлисты",
"Community": "Сообщество", "channel_tab_community_label": "Сообщество",
"search_filters_sort_option_relevance": "по актуальности", "search_filters_sort_option_relevance": "по актуальности",
"search_filters_sort_option_rating": "по рейтингу", "search_filters_sort_option_rating": "по рейтингу",
"search_filters_sort_option_date": "по дате загрузки", "search_filters_sort_option_date": "по дате загрузки",

@ -222,7 +222,7 @@
"About": "O aplikaciji", "About": "O aplikaciji",
"%A %B %-d, %Y": "%A %-d %B %Y", "%A %B %-d, %Y": "%A %-d %B %Y",
"Audio mode": "Avdio način", "Audio mode": "Avdio način",
"Videos": "Videoposnetki", "channel_tab_videos_label": "Videoposnetki",
"search_filters_date_label": "Datum nalaganja", "search_filters_date_label": "Datum nalaganja",
"search_filters_date_option_today": "Danes", "search_filters_date_option_today": "Danes",
"search_filters_date_option_week": "Ta teden", "search_filters_date_option_week": "Ta teden",
@ -455,7 +455,7 @@
"Download": "Prenesi", "Download": "Prenesi",
"permalink": "stalna povezava", "permalink": "stalna povezava",
"`x` marked it with a ❤": "`x` ga je označil/a z ❤", "`x` marked it with a ❤": "`x` ga je označil/a z ❤",
"Community": "Skupnost", "channel_tab_community_label": "Skupnost",
"search_filters_features_option_three_sixty": "360°", "search_filters_features_option_three_sixty": "360°",
"Video mode": "Video način", "Video mode": "Video način",
"search_filters_features_option_c_commons": "Creative Commons", "search_filters_features_option_c_commons": "Creative Commons",

@ -259,10 +259,10 @@
"YouTube comment permalink": "Permalidhje komenti YouTube", "YouTube comment permalink": "Permalidhje komenti YouTube",
"Audio mode": "Mënyrë për audion", "Audio mode": "Mënyrë për audion",
"Playlists": "Luajlista", "Playlists": "Luajlista",
"Community": "Bashkësi", "channel_tab_community_label": "Bashkësi",
"search_filters_sort_option_relevance": "Rëndësi", "search_filters_sort_option_relevance": "Rëndësi",
"Video mode": "Mënyrë video", "Video mode": "Mënyrë video",
"Videos": "Video", "channel_tab_videos_label": "Video",
"search_filters_sort_option_rating": "Vlerësim", "search_filters_sort_option_rating": "Vlerësim",
"search_filters_sort_option_date": "Datë ngarkimi", "search_filters_sort_option_date": "Datë ngarkimi",
"search_filters_sort_option_views": "Numër parjesh", "search_filters_sort_option_views": "Numër parjesh",

@ -257,7 +257,7 @@
"preferences_volume_label": "Jačina zvuka: ", "preferences_volume_label": "Jačina zvuka: ",
"preferences_locale_label": "Jezik: ", "preferences_locale_label": "Jezik: ",
"adminprefs_modified_source_code_url_label": "URL veza do skladišta sa Izmenjenom Izvornom Kodom", "adminprefs_modified_source_code_url_label": "URL veza do skladišta sa Izmenjenom Izvornom Kodom",
"Community": "Zajednica", "channel_tab_community_label": "Zajednica",
"Video mode": "Video mod", "Video mode": "Video mod",
"Fallback captions: ": "Titl u slučaju da glavni nije dostupan: ", "Fallback captions: ": "Titl u slučaju da glavni nije dostupan: ",
"Private": "Privatno", "Private": "Privatno",
@ -289,7 +289,7 @@
"Erroneous token": "Pogrešan žeton", "Erroneous token": "Pogrešan žeton",
"Czech": "Češki", "Czech": "Češki",
"Latin": "Latinski", "Latin": "Latinski",
"Videos": "Video klipovi", "channel_tab_videos_label": "Video klipovi",
"search_filters_features_option_four_k": "4К", "search_filters_features_option_four_k": "4К",
"footer_donate_page": "Doniraj", "footer_donate_page": "Doniraj",
"English": "Engleski", "English": "Engleski",

@ -245,7 +245,7 @@
"(edited)": "(измењено)", "(edited)": "(измењено)",
"`x` marked it with a ❤": "`x` је означио/ла ово са ❤", "`x` marked it with a ❤": "`x` је означио/ла ово са ❤",
"Audio mode": "Аудио мод", "Audio mode": "Аудио мод",
"Videos": "Видео клипови", "channel_tab_videos_label": "Видео клипови",
"search_filters_sort_option_views": "Број прегледа", "search_filters_sort_option_views": "Број прегледа",
"search_filters_features_label": "Карактеристике", "search_filters_features_label": "Карактеристике",
"search_filters_date_option_today": "Данас", "search_filters_date_option_today": "Данас",
@ -298,7 +298,7 @@
"Ukrainian": "Украјински", "Ukrainian": "Украјински",
"permalink": "трајна веза", "permalink": "трајна веза",
"Pashto": "Паштунски", "Pashto": "Паштунски",
"Community": "Заједница", "channel_tab_community_label": "Заједница",
"Sindhi": "Синди", "Sindhi": "Синди",
"Could not fetch comments": "Узимање коментара није успело", "Could not fetch comments": "Узимање коментара није успело",
"Bangla": "Бангла/Бенгалски", "Bangla": "Бангла/Бенгалски",

@ -323,9 +323,9 @@
"`x` marked it with a ❤": "`x` lämnade ett ❤", "`x` marked it with a ❤": "`x` lämnade ett ❤",
"Audio mode": "Ljudläge", "Audio mode": "Ljudläge",
"Video mode": "Videoläge", "Video mode": "Videoläge",
"Videos": "Videor", "channel_tab_videos_label": "Videor",
"Playlists": "Spellistor", "Playlists": "Spellistor",
"Community": "Gemenskap", "channel_tab_community_label": "Gemenskap",
"search_filters_sort_option_relevance": "Relevans", "search_filters_sort_option_relevance": "Relevans",
"search_filters_sort_option_rating": "Rankning", "search_filters_sort_option_rating": "Rankning",
"search_filters_sort_option_date": "Datum", "search_filters_sort_option_date": "Datum",

@ -325,9 +325,9 @@
"`x` marked it with a ❤": "`x` ❤ İle İşaretledi", "`x` marked it with a ❤": "`x` ❤ İle İşaretledi",
"Audio mode": "Ses Modu", "Audio mode": "Ses Modu",
"Video mode": "Video Modu", "Video mode": "Video Modu",
"Videos": "Videolar", "channel_tab_videos_label": "Videolar",
"Playlists": "Oynatma Listeleri", "Playlists": "Oynatma Listeleri",
"Community": "Topluluk", "channel_tab_community_label": "Topluluk",
"search_filters_sort_option_relevance": "İlgi", "search_filters_sort_option_relevance": "İlgi",
"search_filters_sort_option_rating": "Değerlendirme", "search_filters_sort_option_rating": "Değerlendirme",
"search_filters_sort_option_date": "Yükleme Tarihi", "search_filters_sort_option_date": "Yükleme Tarihi",

@ -315,9 +315,9 @@
"`x` marked it with a ❤": "❤ цьому від каналу `x`", "`x` marked it with a ❤": "❤ цьому від каналу `x`",
"Audio mode": "Аудіорежим", "Audio mode": "Аудіорежим",
"Video mode": "Відеорежим", "Video mode": "Відеорежим",
"Videos": "Відео", "channel_tab_videos_label": "Відео",
"Playlists": "Плейлисти", "Playlists": "Плейлисти",
"Community": "Спільнота", "channel_tab_community_label": "Спільнота",
"Current version: ": "Поточна версія: ", "Current version: ": "Поточна версія: ",
"generic_views_count_0": "{{count}} перегляд", "generic_views_count_0": "{{count}} перегляд",
"generic_views_count_1": "{{count}} перегляди", "generic_views_count_1": "{{count}} перегляди",

@ -311,9 +311,9 @@
"`x` marked it with a ❤": "` x` đã đánh dấu nó bằng một ❤", "`x` marked it with a ❤": "` x` đã đánh dấu nó bằng một ❤",
"Audio mode": "Chế độ âm thanh", "Audio mode": "Chế độ âm thanh",
"Video mode": "Chế độ quay", "Video mode": "Chế độ quay",
"Videos": "Video", "channel_tab_videos_label": "Video",
"Playlists": "Danh sách phát", "Playlists": "Danh sách phát",
"Community": "Cộng đồng", "channel_tab_community_label": "Cộng đồng",
"search_filters_sort_option_relevance": "liên quan", "search_filters_sort_option_relevance": "liên quan",
"search_filters_sort_option_rating": "Xếp hạng", "search_filters_sort_option_rating": "Xếp hạng",
"search_filters_sort_option_date": "ngày", "search_filters_sort_option_date": "ngày",

@ -341,9 +341,9 @@
"`x` marked it with a ❤": "`x` 为此加 ❤", "`x` marked it with a ❤": "`x` 为此加 ❤",
"Audio mode": "音频模式", "Audio mode": "音频模式",
"Video mode": "视频模式", "Video mode": "视频模式",
"Videos": "视频", "channel_tab_videos_label": "视频",
"Playlists": "播放列表", "Playlists": "播放列表",
"Community": "社区", "channel_tab_community_label": "社区",
"search_filters_sort_option_relevance": "相关度", "search_filters_sort_option_relevance": "相关度",
"search_filters_sort_option_rating": "评分", "search_filters_sort_option_rating": "评分",
"search_filters_sort_option_date": "上传日期", "search_filters_sort_option_date": "上传日期",

@ -341,9 +341,9 @@
"`x` marked it with a ❤": "`x` 為此標記 ❤", "`x` marked it with a ❤": "`x` 為此標記 ❤",
"Audio mode": "音訊模式", "Audio mode": "音訊模式",
"Video mode": "視訊模式", "Video mode": "視訊模式",
"Videos": "影片", "channel_tab_videos_label": "影片",
"Playlists": "播放清單", "Playlists": "播放清單",
"Community": "社群", "channel_tab_community_label": "社群",
"search_filters_sort_option_relevance": "關聯", "search_filters_sort_option_relevance": "關聯",
"search_filters_sort_option_rating": "評分", "search_filters_sort_option_rating": "評分",
"search_filters_sort_option_date": "日期", "search_filters_sort_option_date": "日期",

@ -34,6 +34,7 @@ require "protodec/utils"
require "./invidious/database/*" require "./invidious/database/*"
require "./invidious/database/migrations/*" require "./invidious/database/migrations/*"
require "./invidious/http_server/*"
require "./invidious/helpers/*" require "./invidious/helpers/*"
require "./invidious/yt_backend/*" require "./invidious/yt_backend/*"
require "./invidious/frontend/*" require "./invidious/frontend/*"

@ -0,0 +1,20 @@
module Invidious::HttpServer
module Utils
extend self
def proxy_video_url(raw_url : String, *, region : String? = nil, absolute : Bool = false)
url = URI.parse(raw_url)
# Add some URL parameters
params = url.query_params
params["host"] = url.host.not_nil! # Should never be nil, in theory
params["region"] = region if !region.nil?
if absolute
return "#{HOST_URL}#{url.request_target}?#{params}"
else
return "#{url.request_target}?#{params}"
end
end
end
end

@ -3,7 +3,7 @@ require "json"
module Invidious::JSONify::APIv1 module Invidious::JSONify::APIv1
extend self extend self
def video(video : Video, json : JSON::Builder, *, locale : String?) def video(video : Video, json : JSON::Builder, *, locale : String?, proxy : Bool = false)
json.object do json.object do
json.field "type", video.video_type json.field "type", video.video_type
@ -89,7 +89,14 @@ module Invidious::JSONify::APIv1
# Not available on MPEG-4 Timed Text (`text/mp4`) streams (livestreams only) # Not available on MPEG-4 Timed Text (`text/mp4`) streams (livestreams only)
json.field "bitrate", fmt["bitrate"].as_i.to_s if fmt["bitrate"]? json.field "bitrate", fmt["bitrate"].as_i.to_s if fmt["bitrate"]?
json.field "url", fmt["url"] if proxy
json.field "url", Invidious::HttpServer::Utils.proxy_video_url(
fmt["url"].to_s, absolute: true
)
else
json.field "url", fmt["url"]
end
json.field "itag", fmt["itag"].as_i.to_s json.field "itag", fmt["itag"].as_i.to_s
json.field "type", fmt["mimeType"] json.field "type", fmt["mimeType"]
json.field "clen", fmt["contentLength"]? || "-1" json.field "clen", fmt["contentLength"]? || "-1"

@ -29,7 +29,7 @@ module Invidious::Routes::API::Manifest
if local if local
uri = URI.parse(url) uri = URI.parse(url)
url = "#{uri.request_target}host/#{uri.host}/" url = "#{HOST_URL}#{uri.request_target}host/#{uri.host}/"
end end
"<BaseURL>#{url}</BaseURL>" "<BaseURL>#{url}</BaseURL>"
@ -42,7 +42,7 @@ module Invidious::Routes::API::Manifest
if local if local
adaptive_fmts.each do |fmt| adaptive_fmts.each do |fmt|
fmt["url"] = JSON::Any.new(URI.parse(fmt["url"].as_s).request_target) fmt["url"] = JSON::Any.new("#{HOST_URL}#{URI.parse(fmt["url"].as_s).request_target}")
end end
end end

@ -6,6 +6,7 @@ module Invidious::Routes::API::V1::Videos
id = env.params.url["id"] id = env.params.url["id"]
region = env.params.query["region"]? region = env.params.query["region"]?
proxy = {"1", "true"}.any? &.== env.params.query["local"]?
begin begin
video = get_video(id, region: region) video = get_video(id, region: region)
@ -15,7 +16,9 @@ module Invidious::Routes::API::V1::Videos
return error_json(500, ex) return error_json(500, ex)
end end
video.to_json(locale, nil) return JSON.build do |json|
Invidious::JSONify::APIv1.video(video, json, locale: locale, proxy: proxy)
end
end end
def self.captions(env) def self.captions(env)

@ -35,6 +35,13 @@ module Invidious::Routes::VideoPlayback
end end
end end
# See: https://github.com/iv-org/invidious/issues/3302
range_header = env.request.headers["Range"]?
if range_header.nil?
range_for_head = query_params["range"]? || "0-640"
headers["Range"] = "bytes=#{range_for_head}"
end
client = make_client(URI.parse(host), region) client = make_client(URI.parse(host), region)
response = HTTP::Client::Response.new(500) response = HTTP::Client::Response.new(500)
error = "" error = ""
@ -70,6 +77,9 @@ module Invidious::Routes::VideoPlayback
end end
end end
# Remove the Range header added previously.
headers.delete("Range") if range_header.nil?
if response.status_code >= 400 if response.status_code >= 400
env.response.content_type = "text/plain" env.response.content_type = "text/plain"
haltf env, response.status_code haltf env, response.status_code
@ -91,14 +101,8 @@ module Invidious::Routes::VideoPlayback
env.response.headers["Access-Control-Allow-Origin"] = "*" env.response.headers["Access-Control-Allow-Origin"] = "*"
if location = resp.headers["Location"]? if location = resp.headers["Location"]?
location = URI.parse(location) url = Invidious::HttpServer::Utils.proxy_video_url(location, region: region)
location = "#{location.request_target}&host=#{location.host}" return env.redirect url
if region
location += "&region=#{region}"
end
return env.redirect location
end end
IO.copy(resp.body_io, env.response) IO.copy(resp.body_io, env.response)

@ -66,8 +66,10 @@ def extract_video_info(video_id : String, proxy_region : String? = nil)
reason ||= subreason.try &.[]("runs").as_a.map(&.[]("text")).join("") reason ||= subreason.try &.[]("runs").as_a.map(&.[]("text")).join("")
reason ||= player_response.dig("playabilityStatus", "reason").as_s reason ||= player_response.dig("playabilityStatus", "reason").as_s
# Stop here if video is not a scheduled livestream # Stop here if video is not a scheduled livestream or
if !{"LIVE_STREAM_OFFLINE", "LOGIN_REQUIRED"}.any?(playability_status) # for LOGIN_REQUIRED when videoDetails element is not found because retrying won't help
if !{"LIVE_STREAM_OFFLINE", "LOGIN_REQUIRED"}.any?(playability_status) ||
playability_status == "LOGIN_REQUIRED" && !player_response.dig?("videoDetails")
return { return {
"version" => JSON::Any.new(Video::SCHEMA_VERSION.to_i64), "version" => JSON::Any.new(Video::SCHEMA_VERSION.to_i64),
"reason" => JSON::Any.new(reason), "reason" => JSON::Any.new(reason),

Loading…
Cancel
Save