Made beforeValidate call compatible