Review main Merged

70717[TASK] Explicitly set ContentObjectRenderer in USER cObj

Christian Kuhn CR +2 V +2 Normal +157 −10 updated 08/23/21, 17:52

Commit message

Handing around ContentObjectRenderer in the frontend
is tricky and intransparent. Especially class instances
created via ContentObjectRenderer->callUserFunction()
get an instance of it set through public property $cObj
in the consuming class. This is typically the case for
USER and USER_INT type frontend plugins.

The patch deprecates using this public property and
calls the method setContentObjectRenderer() instead.

This explicit method call is much easier to see,
break point and follow. The state handling of
ContentObjectRenderer is far from obvious, the
change helps debugging and refactoring this further.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 1

Files 9