faulty register check fix
fixing register bug