Error when change PHP version from 5.6 to 7.4

Elgg 2.3.14

I changed the PHP version from 5.6 to and got the following error:

Fatal error: Declaration of hypeJunction\Interactions\Comment::save() must be compatible with ElggComment::save($update_last_action = true) in mod/hypeInteractions/classes/hypeJunction/Interactions/Comment.php on line 161

Far from being PHP expert :)

How to fix?

Thank you

  • Change on:

    public function save($update_last_action = null) {
         $result = false;
         $update_last_action = true;
         if (elgg_trigger_before_event('create', 'object', $this)) {
               $result = parent::save();
               if ($result && $update_last_action) {
                   elgg_trigger_after_event('create', 'object', $this);
          return $result;
  • Works great.

    Thank you very much RvR.

    I wish I can do it myself some day... maybe next incarnation .... :)