You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The user I'm signed in with is Admin. But, I'm unable to remove a nested entry in a matrix field. I can update the content in the selected nested entry. The matrix can add max 1 entry. The entry type selected in the matrix is updateable after creating, but I can't remove the nested element. Whenever I click remove in the options for the field, I get the following error even though my user is Admin: User is not authorized to perform this action
Trace:
2024-12-05 21:07:09 [web.ERROR] [yii\web\HttpException:403] yii\web\ForbiddenHttpException: User is not authorized to perform this action in /app/backend/vendor/craftcms/cms/src/controllers/NestedElementsController.php:65
Stack trace:
#0 /app/backend/vendor/yiisoft/yii2/base/Controller.php(176): craft\controllers\NestedElementsController->beforeAction(Object(yii\base\InlineAction))
#1 /app/backend/vendor/yiisoft/yii2/base/Module.php(552): yii\base\Controller->runAction('delete', Array)
#2 /app/backend/vendor/craftcms/cms/src/web/Application.php(350): yii\base\Module->runAction('nested-elements...', Array)
#3 /app/backend/vendor/craftcms/cms/src/web/Application.php(649): craft\web\Application->runAction('nested-elements...', Array)
#4 /app/backend/vendor/craftcms/cms/src/web/Application.php(312): craft\web\Application->_processActionRequest(Object(craft\web\Request))
#5 /app/backend/vendor/yiisoft/yii2/base/Application.php(384): craft\web\Application->handleRequest(Object(craft\web\Request))
#6 /app/backend/web/index.php(12): yii\base\Application->run()
#7 {main} {"memory":4049240,"exception":"[object] (yii\\web\\ForbiddenHttpException(code: 0): User is not authorized to perform this action at /app/backend/vendor/craftcms/cms/src/controllers/NestedElementsController.php:65)"}
Steps to reproduce
Login to the cms as an admin account.
Add a matrix field to a sections entry type, and allow it to add max 1 entry type.
Add the entry type to the matrix field in the entry, and save. It worked saving.
Try to remove the nested entry type.
It fails with the errors described.
Expected behavior
I would expect that the nested were deleted, and I could then add a new nested entry.
Actual behavior
I can't delete the nested entry.
Craft CMS version
5.5.5
PHP version
8.2
Operating system and version
No response
Database type and version
No response
Image driver and version
No response
Installed plugins and versions
The text was updated successfully, but these errors were encountered:
Hi, thanks for getting in touch! I’m not able to reproduce this.
What view mode is this matrix field using? Could you also please turn on the safeMode and see if you’re still getting the same behaviour?
What happened?
Description
The user I'm signed in with is Admin. But, I'm unable to remove a nested entry in a matrix field. I can update the content in the selected nested entry. The matrix can add max 1 entry. The entry type selected in the matrix is updateable after creating, but I can't remove the nested element. Whenever I click remove in the options for the field, I get the following error even though my user is Admin:
User is not authorized to perform this action
Trace:
Steps to reproduce
Expected behavior
I would expect that the nested were deleted, and I could then add a new nested entry.
Actual behavior
I can't delete the nested entry.
Craft CMS version
5.5.5
PHP version
8.2
Operating system and version
No response
Database type and version
No response
Image driver and version
No response
Installed plugins and versions
The text was updated successfully, but these errors were encountered: