Add mangadex lang code csv to src/assets

This commit is contained in:
Alex Ling
2020-02-20 23:41:40 +00:00
parent 1649f286aa
commit fd342fe1ee
2 changed files with 42 additions and 1 deletions

View File

@@ -164,7 +164,7 @@ module Mangadex
class API
def initialize(@base_url = "https://mangadex.org/api/")
@lang = {} of String => String
CSV.each_row {{read_file "src/lang.csv"}} do |row|
CSV.each_row {{read_file "src/assets/lang_codes.csv"}} do |row|
@lang[row[1]] = row[0]
end
end