fix(files_trashbin): has-preview must return true or false

Currently it returned the boolean value, but PHP will turn it into an
integer...

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
This commit is contained in:
Ferdinand Thiessen 2025-08-07 01:23:10 +02:00
parent 09b0698255
commit 6b0bce8a2d
No known key found for this signature in database
GPG key ID: 45FAE7268762B400

View file

@ -104,8 +104,8 @@ class TrashbinPlugin extends ServerPlugin {
return $node->getFileId();
});
$propFind->handle(FilesPlugin::HAS_PREVIEW_PROPERTYNAME, function () use ($node) {
return $this->previewManager->isAvailable($node->getFileInfo());
$propFind->handle(FilesPlugin::HAS_PREVIEW_PROPERTYNAME, function () use ($node): string {
return $this->previewManager->isAvailable($node->getFileInfo()) ? 'true' : 'false';
});
$propFind->handle(FilesPlugin::MOUNT_TYPE_PROPERTYNAME, function () {