Skip to content

Commit

Permalink
Merge pull request #412 from Casinelli/master
Browse files Browse the repository at this point in the history
Fix namespace
  • Loading branch information
andrew13 committed Nov 10, 2015
2 parents 0a42197 + 3a22fe6 commit 2f97b7c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/Entrust/EntrustServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,29 +60,29 @@ public function register()
private function bladeDirectives()
{
// Call to Entrust::hasRole
Blade::directive('role', function($expression) {
\Blade::directive('role', function($expression) {
return "<?php if (\\Entrust::hasRole{$expression}) : ?>";
});

Blade::directive('endrole', function($expression) {
\Blade::directive('endrole', function($expression) {
return "<?php endif; // Entrust::hasRole ?>";
});

// Call to Entrust::can
Blade::directive('permission', function($expression) {
\Blade::directive('permission', function($expression) {
return "<?php if (\\Entrust::can{$expression}) : ?>";
});

Blade::directive('endpermission', function($expression) {
\Blade::directive('endpermission', function($expression) {
return "<?php endif; // Entrust::can ?>";
});

// Call to Entrust::ability
Blade::directive('ability', function($expression) {
\Blade::directive('ability', function($expression) {
return "<?php if (\\Entrust::ability{$expression}) : ?>";
});

Blade::directive('endability', function($expression) {
\Blade::directive('endability', function($expression) {
return "<?php endif; // Entrust::ability ?>";
});
}
Expand Down

0 comments on commit 2f97b7c

Please sign in to comment.