Problem saving music file to document directory with network.download

I am trying to save a music file to document directory, but i get a weird json file with a bunch of text. But when I use network.download to download to temp directory it works fine. I suspect it is bug, just wondering if it is limitation network.download. This code was tested on the latest daily builds and latest public build

local id = "690199" local downloadUrl = "https://www.newgrounds.com/audio/download/"..id network.download( downloadUrl, "GET", function ( ev ) if not ev.error then print("no error") else --error print("error") end end, nil, id..".wav", system.DocumentsDirectory )  

Never mind .mp3 works, but that is interesting how .wav cannot be saved to document directory

edit: that is weird .mp3 is not working and giving me a myData.json file, i think this might be an error on newgrounds. Switch to wav and now that works.

edit2: this is not a bug, i was just making to many request and the site got mad at me

Yea, sites can get aggressive at times. I recently transferred my web hosting to a new hosting provider and after 5 failed login attempts to my cPanel they blocked my IP at their firewall.

Rob

Never mind .mp3 works, but that is interesting how .wav cannot be saved to document directory

edit: that is weird .mp3 is not working and giving me a myData.json file, i think this might be an error on newgrounds. Switch to wav and now that works.

edit2: this is not a bug, i was just making to many request and the site got mad at me

Yea, sites can get aggressive at times. I recently transferred my web hosting to a new hosting provider and after 5 failed login attempts to my cPanel they blocked my IP at their firewall.

Rob