Add missing requirement for Perl6::Junction
[catagits/Catalyst-Manual.git] / lib / Catalyst / Manual / Tutorial / 06_Authorization.pod
index 456c5e5..6515d48 100644 (file)
@@ -78,21 +78,21 @@ Catalyst.
 
 Edit C<lib/MyApp.pm> and add C<Authorization::Roles> to the list:
 
-       # Load plugins
-       use Catalyst qw/
-               -Debug
-               ConfigLoader
-               Static::Simple
-
-               StackTrace
-
-               Authentication
-               Authorization::Roles
-
-               Session
-               Session::Store::FastMmap
-               Session::State::Cookie
-       /;
+    # Load plugins
+    use Catalyst qw/
+        -Debug
+        ConfigLoader
+        Static::Simple
+        
+        StackTrace
+        
+        Authentication
+        Authorization::Roles
+        
+        Session
+        Session::Store::FastMmap
+        Session::State::Cookie
+    /;
 
 Once again, include this additional plugin as a new dependency in 
 the Makefile.PL file like this:
@@ -174,7 +174,7 @@ updating C<url_create> to match the following code:
     
             # Assign the Book object to the stash and set template
             $c->stash(book     => $book,
-                                         template => 'books/create_done.tt2');
+                      template => 'books/create_done.tt2');
         } else {
             # Provide very simple feedback to the user.
             $c->response->body('Unauthorized!');
@@ -255,7 +255,7 @@ this method to our Result Class.  Open
 C<lib/MyApp/Schema/Result/User.pm> and add the following method below 
 the "C<DO NOT MODIFY ...>" line:
 
-    =head 2 has_role
+    =head2 has_role
     
     Check if a user has the specified role
     
@@ -269,6 +269,11 @@ the "C<DO NOT MODIFY ...>" line:
         return any(map { $_->role } $self->roles) eq $role;
     }
 
+Let's also add Perl6::Junction to the requirements listed in 
+Makefile.PL:
+
+    requires 'Perl6::Junction';
+
 Now we need to add some enforcement inside our controller.  Open
 C<lib/MyApp/Controller/Books.pm> and update the C<delete> method to
 match the following code:
@@ -343,6 +348,6 @@ Please report any errors, issues or suggestions to the author.  The
 most recent version of the Catalyst Tutorial can be found at
 L<http://dev.catalyst.perl.org/repos/Catalyst/Catalyst-Manual/5.80/trunk/lib/Catalyst/Manual/Tutorial/>.
 
-Copyright 2006-2008, Kennedy Clark, under Creative Commons License
+Copyright 2006-2010, Kennedy Clark, under Creative Commons License
 (L<http://creativecommons.org/licenses/by-sa/3.0/us/>).