Added nicer handling when user_id is missing