entriphy / sp-playcount-librespot

Modification of librespot-java to provide play count info from Spotify
Apache License 2.0
119 stars 16 forks source link

Fix broken JSON for error messages #10

Closed ghost closed 4 years ago

ghost commented 4 years ago

This fixes an issue where the error messages are not quoted, resulting in invalid JSON like this:

❯ curl -s 'https://api.t4ils.dev/albumPlayCount?albumid=4AICAv06yCiu66i4TOPWg'
{"success": false, "data": albumid is invalid; albumid length does not equal 22}
entriphy commented 4 years ago

Clearly I didn't test this well at all :P

Thanks for the changes!