superawesomeme / moodle-theme_aardvark

Aardvark theme for Moodle
https://moodle.org/plugins/view.php?plugin=theme_aardvark
6 stars 14 forks source link

get_logo_url and get_compact_logo_url should return moodle_url #21

Closed jleyva closed 6 years ago

jleyva commented 6 years ago

Hi, there is a bug in the theme code that is causing the Mobile app to stop working on sites where the theme is enabled:

Problem is here: https://github.com/superawesomeme/moodle-theme_aardvark/blob/74efa85762e8b1e290c7573bc72af2a1d2ea9d14/classes/core_renderer.php#L115

Functions get_logo_url and get_compact_logo_url should return moodle_url instead plain string urls, we've applied a patch in Moodle core to handle this but you should fix it in your plugin as well.

The fix is simple, you can just grab the code from the same function in theme clean to see how we conver a url returned by setting_file_url to a moodle_url: https://github.com/moodle/moodle/blob/master/theme/clean/classes/core_renderer.php#L132

superawesomeme commented 6 years ago

Thank you. I've implimented this now.