fix login issues and cleanup routes