Problem/Motivation

See Drupal core issue: #3483599: Convert all procedural hook implementations to Hook classes

And change record: Most procedural hook implementations have been converted to a hook class

Proposed resolution

Let's follow core's pattern in farmOS.

Remaining tasks

TBD

User interface changes

None.

API changes

None.

Data model changes

None.

Comments

m.stenta created an issue. See original summary.

m.stenta’s picture

Parent issue: » #3488918: [META] farmOS 4.x
m.stenta’s picture

We have another issue open that overlaps/relates to this: #3415475: Replace farmOS hooks with Events + EventSubscribers

I think we can work on this issue as the first priority, since we should follow core's pattern first and foremost.

IIRC the other issue proposes some other changes, so let's review that again and see if/how it needs to be updated

m.stenta’s picture

I wonder if we should consider deprecating the Asset/Log/Plan/etc events, and just recommend using the core hooks as intended.

m.stenta’s picture

There is a draft PR for a Rector rule that automates this conversion here: https://github.com/palantirnet/drupal-rector/pull/308

m.stenta’s picture

Version: 3.x-dev » 4.x-dev
m.stenta’s picture

Status: Active » Needs review
m.stenta’s picture

Status: Needs review » Fixed

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

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

Maintainers, please credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

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