Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After latest update, relation manager seems to not be finding the "activity_log" relation #575

Open
devcflynn opened this issue Dec 10, 2024 · 1 comment

Comments

@devcflynn
Copy link

After the latest updates to the user plugin, I am getting the following error:

Model 'RainLab\User\Models\User' does not contain a definition for 'activity_log'.
thrown in: /modules/backend/behaviors/RelationController.php

But when I check: /plugins/rainlab/user/models/User.php I can clearly see the definition defined:

Lines 153-158:

/**
 * @var array hasMany relations
 */
public $hasMany = [
    'activity_log' => [UserLog::class, 'delete' => true],
];

I am not sure why this happening, but if I figure it out while waiting, I will respond with the solution.

Thanks

@daftspunk
Copy link
Member

Hey @devcflynn

It is actually complaining about not finding this definition:

This could happen if another plugin registers its own relation definitions, thereby removing this one. Check to see if it is the case...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants