Updated database login function
Resolved merge conflict