fix login errors while filesystem is not loaded
also fix login errors while filesystem is not loaded in app.php