4 posts / 0 new
Last post
damien.raemy
Offline
Last seen: 6 months 5 days ago
Joined: 12/21/2018
Call to $this in static method

Hello,

I found a programming error in opigno-lms/web/modules/contrib/opigno_module/src/Controller/ExternalPackageController.php. At the line 207, $this->t(...) is called in method createActivityByPackageType. But at line 83, we can see ExternalPackageController::createActivityByPackageType. This results of an error "Using $this when not in object context"

James Aparicio
James Aparicio's picture
Offline
Last seen: 2 weeks 1 day ago
Staff
Joined: 10/30/2013
Hi damien.raemy,

Hi damien.raemy,

 

Tkx for contibuting.

We will take a look at this.

 

Best regards

damien.raemy
Offline
Last seen: 6 months 5 days ago
Joined: 12/21/2018
Call to undefined method t()

Hi James Aparicio,

Thanks for your feedback.

I found other errors that are more or less related to this topic (because it also concerns the call to t() method). The TincanContentAnswerAssistant call t() method, but does not implement it. Here is an example of error message: MESSAGE Error: Call to undefined method Drupal\opigno_tincan_activity\TincanContentAnswerAssistant::t() in Drupal\opigno_tincan_activity\TincanContentAnswerAssistant->getScoreFromLrs() (line 154 of /var/www/html/opigno-lms/web/modules/contrib/opigno_module/ActivityTypes/opigno_tincan_activity/src/TincanContentAnswerAssistant.php) #0

James Aparicio
James Aparicio's picture
Offline
Last seen: 2 weeks 1 day ago
Staff
Joined: 10/30/2013
Hi damien.raemy,

Hi damien.raemy,

Tkx, we already fixed that internally. 

The changes will be part of the next release .

 

Best regards