Fix redirect issue if login is wrong
Switching patient info method to use native SQL queries