This could be misleading to people unfamiliar with Go. The underlying structure of strings are byte arrays, which is why you have to be careful when you loop over a string because it'll give you byte-by-byte not character-by-character.
My guess is many places byte arrays are returned have to do with that, and the ability to efficiently change the size of the array without allocating new memory.
Byte arrays are used because they can be unmarshalled, whereas strings cannot.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
This could be misleading to people unfamiliar with Go. The underlying structure of strings are byte arrays, which is why you have to be careful when you loop over a string because it'll give you byte-by-byte not character-by-character.
Byte arrays are used because they can be unmarshalled, whereas strings cannot.