Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
lib
unicaen
auth
Commits
57f3297b
Commit
57f3297b
authored
Jun 16, 2016
by
Laurent Lécluse
Browse files
Ajout de commentaires activables pour tracer les exécutions d'assertions
parent
c2e7a7cd
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/UnicaenAuth/Assertion/AbstractAssertion.php
View file @
57f3297b
...
...
@@ -74,7 +74,7 @@ abstract class AbstractAssertion implements AssertionInterface, ServiceLocatorAw
$this
->
init
();
switch
(
true
)
{
case
$this
->
detectPrivilege
(
$resource
)
:
// var_dump('assertPrivilege '.get_class($this).' '.$resource->getResourceId().' '.$privilege);
return
$this
->
assertPrivilege
(
ltrim
(
strstr
(
$resource
,
'/'
),
'/'
),
$privilege
);
case
$this
->
detectController
(
$resource
)
:
...
...
@@ -85,14 +85,15 @@ abstract class AbstractAssertion implements AssertionInterface, ServiceLocatorAw
$controller
=
substr
(
$resource
,
$spos
,
$dpos
-
$spos
-
1
);
$action
=
substr
(
$resource
,
$dpos
);
// var_dump('assertController '.get_class($this).' '.$controller.'.'.$action.' '.$privilege);
return
$this
->
assertController
(
$controller
,
$action
,
$privilege
);
case
$this
->
detectEntity
(
$resource
)
:
// var_dump('assertEntity '.get_class($this).' '.$resource->getResourceId().' '.$privilege);
return
$this
->
assertEntity
(
$resource
,
$privilege
);
default
:
// var_dump('assertOther '.get_class($this).' '.$resource->getResourceId().' '.$privilege);
return
$this
->
assertOther
(
$resource
,
$privilege
);
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment