File tree 1 file changed +4
-14
lines changed
1 file changed +4
-14
lines changed Original file line number Diff line number Diff line change 1
1
package describe
2
2
3
3
import (
4
- "bytes"
5
4
"fmt"
6
5
"path/filepath"
7
6
"sort"
@@ -1273,26 +1272,17 @@ func DescribePolicy(policy *authorizationapi.Policy) (string, error) {
1273
1272
})
1274
1273
}
1275
1274
1276
- const PolicyRuleHeadings = "Verbs\t Non-Resource URLs\t Extension \ t Resource Names\t API Groups\t Resources"
1275
+ const PolicyRuleHeadings = "Verbs\t Non-Resource URLs\t Resource Names\t API Groups\t Resources"
1277
1276
1278
1277
func DescribePolicyRule (out * tabwriter.Writer , rule authorizationapi.PolicyRule , indent string ) {
1279
- extensionString := ""
1280
1278
if rule .AttributeRestrictions != nil {
1281
- extensionString = fmt .Sprintf ("%#v" , rule .AttributeRestrictions )
1282
-
1283
- buffer := new (bytes.Buffer )
1284
-
1285
- // TODO(rebase-1.6): we probably need a non-nil encoder and decoder
1286
- printer := NewHumanReadablePrinter (nil , nil , kprinters.PrintOptions {NoHeaders : true })
1287
- if err := printer .PrintObj (rule .AttributeRestrictions , buffer ); err == nil {
1288
- extensionString = strings .TrimSpace (buffer .String ())
1289
- }
1279
+ // We are not supporting attribute restrictions going forward
1280
+ return
1290
1281
}
1291
1282
1292
- fmt .Fprintf (out , indent + "%v\t %v\t %v\t %v\t %v\t %v \ n " ,
1283
+ fmt .Fprintf (out , indent + "%v\t %v\t %v\t %v\t %v\n " ,
1293
1284
rule .Verbs .List (),
1294
1285
rule .NonResourceURLs .List (),
1295
- extensionString ,
1296
1286
rule .ResourceNames .List (),
1297
1287
rule .APIGroups ,
1298
1288
rule .Resources .List (),
You can’t perform that action at this time.
0 commit comments