catalyst / moodle-mod_reengagement

Allows timed release of content and emails users to remind them to complete a course activity
23 stars 39 forks source link

get_fast_modinfo once per course and caching it #162

Closed rajandangi closed 2 months ago

rajandangi commented 2 months ago

This PR optimizes the reengagement_get_startusers function by loading the modinfo once per course and caching it to avoid multiple calls to get_fast_modinfo.

danmarsden commented 2 months ago

I'd be surprised if this makes much of a difference to performance, but the code reads better and does the same thing so I'm happy to merge.