added addmin for login and logout