fixed json logged in bug
Fixes for json. /json was throwing an error if the user was not logged in