Fixing bug in Validator