Fixed an issue in database that caused a invalid user id