updated checkRegister