Changed login code to use server session
Added functionality to store changed candidate details in database