nextcloud/server · error · Sabre\DAV\Exception
Property "$name" has an invalid value of type {gettype($valu
Error message
Property "$name" has an invalid value of type {gettype($value)} What it means
Error "Property "$name" has an invalid value of type {gettype($value)}" thrown in nextcloud/server.
Source
Thrown at apps/dav/lib/DAV/CustomPropertiesBackend.php:650
0,
$e,
);
}
if (is_scalar($value)) {
$valueType = self::PROPERTY_TYPE_STRING;
} elseif ($value instanceof Complex) {
$valueType = self::PROPERTY_TYPE_XML;
$value = $value->getXml();
} elseif ($value instanceof Href) {
$valueType = self::PROPERTY_TYPE_HREF;
$value = $value->getHref();
} else {
if (is_array($value)) {
// For array only allow scalar values
self::checkIsArrayOfScalar($name, $value);
} elseif (!is_object($value)) {
throw new DavException(
"Property \"$name\" has an invalid value of type " . gettype($value),
);
} else {
if (!in_array($value::class, self::ALLOWED_SERIALIZED_CLASSES)) {
throw new DavException(
"Property \"$name\" has an invalid value of class " . $value::class,
);
}
}
$valueType = self::PROPERTY_TYPE_OBJECT;
// serialize produces null character
// these can not be properly stored in some databases and need to be replaced
$value = str_replace(chr(0), '\x00', serialize($value));
}
return [$value, $valueType];
}
/**View on GitHub (pinned to ecdeb153ff)
When it happens
Trigger: Thrown at apps/dav/lib/DAV/CustomPropertiesBackend.php:650 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of nextcloud/server@ecdeb153ff (2026-08-17).
Data as JSON: /api/errors/a7dc74588c94bca9.
Report an issue: GitHub.