Logging password issue 

adding logic to check if user is loging in then re-direct post request to avoid logging of password in history table