one way implementing validator