MetaModels / core

MetaModels Core Module
GNU Lesser General Public License v3.0
96 stars 42 forks source link

Can not add a user group in Contao #1340

Closed webwerkwien closed 5 years ago

webwerkwien commented 5 years ago

While having no user group yet, it throws the following error if I am trying to add one:

Type error: Too few arguments to function tl_user_group::getModules(), 0 passed in /var/www/clients/client2/web748/web/contao/vendor/metamodels/core/src/CoreBundle/Contao/Hooks/FixupUserGroupModules.php on line 86 and exactly 1 expected

Using Contao 4.4.44, attribute_timestamp 2.1.0, bundle_start 2.1.2, contao-frontend-editing 2.1.0 and PHP 7.2.16. I do not use any other extensions.

webwerkwien commented 5 years ago

Good morning, I deleted the extensions and was able to create new user groups. Afterwards I installed MetaModels Core 2.1.5, some filters, some attributes and the contao-frontend-editing. Again there is the error, when I try to add a new user group and when I try to edit an existing one.

zonky2 commented 5 years ago

I can check this next week...

webwerkwien commented 5 years ago

Hi. I checked Contao functions like https://github.com/contao/core-bundle/blob/6addfbbff0bc9eecb6e74a78c21737bbb8ecc37f/src/Resources/contao/dca/tl_user.php

So I changed $modules = $original->getModules(); to $modules = $original->getModules($dataContainer); . Not knowing what I am doing and if there is any impact on MetaModels I can know add and edit user groups in Contao!

kampfq commented 5 years ago

i created a pull request for this, #1341

discordier commented 5 years ago

Closing in favor of #1341

zonky2 commented 5 years ago

PR is not checked to me and I can't reproduce the error message in any project :(

zonky2 commented 5 years ago

checked :D