Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-51184

Setting $CFG->svgicons in config.php has no effect

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.9.1
    • Fix Version/s: 2.8.8, 2.9.2
    • Component/s: Themes
    • Labels:

      Description

      I want to force the use of png-Icons instead of the svg-icons and therefore set $CFG->svgicons to the boolean false in my config.php. This didn't work as expected, as all values of $CFG will be casted to string through the call to "initialise_cfg()" and its call to "get_config('core')" in setup.php, while the method "theme_config::use_svg_icons()" expects $CFG->svgicons to be of boolean type.

      The bug lies in "use_svg_icons()" as the global policy seems to be that every configuration value will be of type string. But it still made me doubt myself for a moment or two when I put a value of one type in and it magically transformed into a value of another type.

      I only checked for version 2.9.1 but I suspect previous versions will also be affected.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  14/Sep/15