Working on the register error checking