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

Add role_exists to migration tools

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Unverified Fix (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.3.0
    • Fix Version/s: 3.3.2-RC1
    • Component/s: Migrations
    • Labels:
      None

      Description

      Add a permissions tool method "role_exists"

       

      Sometimes there are users who delete core phpBB roles, and when they try to install an extension that sets permissions on that deleted role, all the migration currently does is throw an exception which causes the install to fail. And that causes support requests for the author.

       

      A role exists method would allow the ext author to check if a role esists before setting a permission on it:

      array('if', array(
          array('permission.role_exists', array('ROLE_USER_STANDARD')),
          array('permission.permission_set', array('ROLE_USER_STANDARD', 'u_foo')),
      )),
      

       

        Attachments

          Activity

            People

            Assignee:
            Marc Marc
            Reporter:
            MattF Matt Friedman
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: