From freesound.js#L84-87...
if (xhr.readyState === 4 && [200,201,202].indexOf(xhr.status)>=0){
var data = eval("(" + xhr.responseText + ")");
if(success) success(wrapper?wrapper(data):data);
}
I believe xhr.responseText is a JSON string, in which case JSON.parse can be used to safely parse the data. Is there a reason eval is used instead?
From freesound.js#L84-87...
I believe
xhr.responseTextis a JSON string, in which caseJSON.parsecan be used to safely parse the data. Is there a reasonevalis used instead?