Golang : invalid character ',' looking for beginning of value

In has been a while since I've encounter a strange error message that I couldn't comprehend. However, today is special since I've encountered this weird error message today while writing examples for Golang.

invalid character ',' looking for beginning of value

and the error was caused by a comma , at the end of each JSON data line

 var jsonDataStream = 

to get rid of this error, simply remove the , will do

 var jsonDataStream = 

See https://www.socketloop.com/references/golang-encoding-json-newdecoder-function-example

By Adam Ng

IF you gain some knowledge or the information here solved your programming problem. Please consider donating to the less fortunate or some charities that you like. Apart from donation, planting trees, volunteering or reducing your carbon footprint will be great too.