mirror of
https://github.com/iv-org/invidious.git
synced 2024-12-28 11:00:24 +05:30
Fix(user/importers): Fixed typos
This commit is contained in:
parent
16f3f0979f
commit
d3eca5ff20
@ -30,7 +30,7 @@ services:
|
|||||||
# domain:
|
# domain:
|
||||||
# https_only: false
|
# https_only: false
|
||||||
# statistics_enabled: false
|
# statistics_enabled: false
|
||||||
hmac_key: "CHANGE_ME!!"
|
hmac_key: "ahyeef5xahyohliefi3A"
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: wget -nv --tries=1 --spider http://127.0.0.1:3000/api/v1/trending || exit 1
|
test: wget -nv --tries=1 --spider http://127.0.0.1:3000/api/v1/trending || exit 1
|
||||||
interval: 30s
|
interval: 30s
|
||||||
|
@ -33,7 +33,7 @@ struct Invidious::User
|
|||||||
# Parse a CSV Google Takeout - Youtube Playlist file
|
# Parse a CSV Google Takeout - Youtube Playlist file
|
||||||
def parse_playlist_export_csv(user : User, playlist_name : String, raw_input : String)
|
def parse_playlist_export_csv(user : User, playlist_name : String, raw_input : String)
|
||||||
# Split the input into head and body content
|
# Split the input into head and body content
|
||||||
raw_head, raw_body = raw_input.strip('\n').split("\n\n", limit: 2, remove_empty: true)
|
raw_head, raw_body = raw_input.split("\n\n", limit: 2, remove_empty: true)
|
||||||
|
|
||||||
# Create the playlist from the head content
|
# Create the playlist from the head content
|
||||||
csv_head = CSV.new(raw_head.strip('\n'), headers: true)
|
csv_head = CSV.new(raw_head.strip('\n'), headers: true)
|
||||||
@ -205,7 +205,7 @@ struct Invidious::User
|
|||||||
extension = filename_array.last
|
extension = filename_array.last
|
||||||
|
|
||||||
if extension == "csv" || type == "text/csv"
|
if extension == "csv" || type == "text/csv"
|
||||||
playlist = parse_playlist_export_csv(user, playlist_name,playlist_name, body)
|
playlist = parse_playlist_export_csv(user, playlist_name, body)
|
||||||
if playlist
|
if playlist
|
||||||
return true
|
return true
|
||||||
else
|
else
|
||||||
@ -217,7 +217,6 @@ struct Invidious::User
|
|||||||
end
|
end
|
||||||
|
|
||||||
def from_youtube_wh(user : User, body : String, filename : String, type : String) : Bool
|
def from_youtube_wh(user : User, body : String, filename : String, type : String) : Bool
|
||||||
filename = filename.split(".")
|
|
||||||
extension = filename.split(".").last
|
extension = filename.split(".").last
|
||||||
|
|
||||||
if extension == "json" || type == "application/json"
|
if extension == "json" || type == "application/json"
|
||||||
|
Loading…
Reference in New Issue
Block a user