From a71181d54bf8c809e716730dd6ac1287fc6309c2 Mon Sep 17 00:00:00 2001 From: mickey Date: Mon, 7 Jul 2014 09:35:07 +0200 Subject: [PATCH] updated the doc a little --- lib/Authorize/Rule.pm | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/Authorize/Rule.pm b/lib/Authorize/Rule.pm index 0b6b19a..1acff33 100644 --- a/lib/Authorize/Rule.pm +++ b/lib/Authorize/Rule.pm @@ -224,7 +224,7 @@ The general structure is: { ENTITY => { RESOURCE => [ - OPTIONAL_LABEL => [ ACTION, RULE1, RULE2, ...RULE10 ], + OPTIONAL_LABEL => [ ACTION, RULE_1, RULE_2, ...RULE_N ], ] } @@ -262,7 +262,8 @@ Traditionally these will be C<1> or C<0>: ... } -Rules are read consecutively and as soon as a rule matches the matching stops. +Rules are read consecutively and as soon as a rule matches the matching stops +and the action value is returned. =head1 EXAMPLES @@ -485,8 +486,11 @@ to allow by default if there is no match. =head2 rules -A hash reference of your permissions, defined by the specification explained +Rules can be either: +- A hash reference of your permissions, defined by the specification explained above. +- A key name (string) indicating this key must exist with no restriction to +the value other than it must be defined. =head1 METHODS