before_validation hooks fixed