Changed register to define.
Changed isRegistred to isDefined.