Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-13937

avatar driver get config name

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Blocker
    • Resolution: Fixed
    • 3.1.4
    • 3.1.8-RC1
    • Extensions
    • None

    Description

      Currently if one tries to create custom avatar driver in an extension, \phpbb\avatar\manager::get_driver_config_name() results in something like allow_avatar_vendor\avatardb\driver\db , which means the config value it would like to store in the database contains slashes, which isn't ideal.

      the get_driver_config_name() method uses this regex to remove the driver name prefix ^phpbb\avatar\driver, but it should also replace all non-alphanumeric characters with spaces, or at least allow drivers to define their own custom name (something like get_name(), but used for config). Or at the very least string replace "\" with "_".

      There is no real way to work around this as get_enabled_drivers() calls it as well, so even if the extension event cleaned up the config name, it still wouldn't enable the avatar driver.

      Attachments

        Issue Links

          Activity

            People

              nicofuma nicofuma
              rfdy rfdy [X] (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: