Dont expect a json response, also be capable to decode

canary
WolverinDEV 2018-11-04 15:12:38 +01:00
parent 89e43ffea6
commit f630e9858e
1 changed files with 2 additions and 0 deletions

View File

@ -90,6 +90,8 @@ namespace sound {
$.ajax({
url: "audio/speech/mapping.json",
success: response => {
if(typeof(response) === "string")
response = JSON.parse(response);
for(const entry of response)
register_sound(entry.key, "speech/" + entry.file);
resolve();