fix: 🐛 change of a bad attribute on dynamic page

This commit is contained in:
Alexis Gousseau 2026-01-20 15:26:39 +01:00
parent a21493aea3
commit e782cad789

View file

@ -253,7 +253,7 @@ class DynamicPage extends Model implements TranslatableModel
{
$oldDynamicPageRoot = self::getModelsCached()->where('id', '!=', $model->getKey())->where('isRoot', true)->first();
if ($oldDynamicPageRoot) {
$oldDynamicPageRoot->publish = PageStatusEnum::unpublished;
$oldDynamicPageRoot->status = PageStatusEnum::unpublished;
$oldDynamicPageRoot->isRoot = false;
$oldDynamicPageRoot->saveQuietly();
}