From 5fdf6f460e8fc066e139c082499f0790a57ea406 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Mon, 14 Dec 2020 18:17:19 +0100 Subject: [PATCH] pass $new=true to $attrdef->validate() --- controllers/class.EditDocument.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controllers/class.EditDocument.php b/controllers/class.EditDocument.php index ff98965d2..680d31577 100644 --- a/controllers/class.EditDocument.php +++ b/controllers/class.EditDocument.php @@ -120,7 +120,7 @@ class SeedDMS_Controller_EditDocument extends SeedDMS_Controller_Common { if($attrdef = $dms->getAttributeDefinition($attrdefid)) { if(null === ($ret = $this->callHook('validateAttribute', $attrdef, $attribute))) { if($attribute) { - if(!$attrdef->validate($attribute)) { + if(!$attrdef->validate($attribute, true)) { $this->errormsg = getAttributeValidationError($attrdef->getValidationError(), $attrdef->getName(), $attribute); return false; }