Fix NullValidator

It seems broken a little ago.
Add required constraint
Refactor: register logic should be put at validator class