Add nullcheck for loggedUser, since cookie does not get cleared instantly on logout. Fixes #70