modified controllers and routes files for authentications