Code adjustment of LoginProvider class.