Return a blank array instead of null if there are no repositories

Fixes a bug where it's impossible to add repositories in the web interface if none are defined.

Note: I don't know any Go, I have barely any idea what I'm doing. I guess this could also be fixed in the web interface JS, whatever you think is best.