Problem/Motivation

An exception is thrown when installing the 3.0.x-dev version of the module:
Error: Call to undefined method Drupal\recurring_events\Hook\RecurringEventsViewsHooks::viewsDataAlter() in recurring_events_views_data_alter() (line 18 of modules/contrib/recurring_events/recurring_events.views.inc).

Steps to reproduce

  1. Install Drupal, standard profile.
  2. Go to /admin/modules modules and install Recurring Events 3.x.

Proposed resolution

The exception is happening because recurring_events_views_data_alter() is calling the wrong method name on RecurringEventsViewsHooks. It's calling
\Drupal::service(RecurringEventsViewsHooks::class)->viewsDataAlter($data);
when it should be calling
\Drupal::service(RecurringEventsViewsHooks::class)->dataAlter($data);

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

muriqui created an issue. See original summary.

muriqui’s picture

Status: Active » Needs review
olegrymar’s picture

StatusFileSize
new70.76 KB

I can confirm that the patch introduced in this https://git.drupalcode.org/project/recurring_events/-/merge_requests/179 merge request fixes the error.

Before:
Before changes

After:
The error is no longer displayed.

jmester13’s picture

Also confirming the patch resolves this matter.

muriqui’s picture

Issue summary: View changes
muriqui’s picture

Status: Needs review » Reviewed & tested by the community

  • muriqui committed 3c0873a4 on 3.0.x
    fix: #3557533 "Call to undefined method" exception thrown by...
muriqui’s picture

Status: Reviewed & tested by the community » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.