fixed databse bug and enabled lowercase login