Added handling for non-authenticated users