merge and refactoring authmanager