fix problem in the register