Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-68581

Improve AuthorizationContainer.add() method description

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • matrix-auth-plugin
    • None
    • matrix-auth-3.1.6

      The new form of AuthorizationContainer.add() has a description that can be confusing.

      It states:

       Works like add(Permission, PermissionEntry) but takes both parameters from a single string of the form PERMISSION_ID:sid (legacy format, implicit 'EITHER' type) or type:PERMISSION_ID:sid (new since 3.0).

      That might lead users to think that:

      add(Jenkins.ADMINISTER, "username")

      would translate directly as:

      add("Jenkins.ADMINISTER:username")

       when the correct form is:

      add("hudson.model.Hudson.Administer:username")

       

      reference: https://github.com/jenkinsci/matrix-auth-plugin/blob/master/src/main/java/org/jenkinsci/plugins/matrixauth/AuthorizationContainer.java#L175

            danielbeck Daniel Beck
            alejdg Alexandre Gomes
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: