tweaked changes
[catagits/Catalyst-Runtime.git] / lib / Catalyst / Upgrading.pod
index 6012f98..094191d 100644 (file)
@@ -2,6 +2,16 @@
 
 Catalyst::Upgrading - Instructions for upgrading to the latest Catalyst
 
+=head1 Upgrading to Catalyst 5.90100
+
+The method C<last_error> in L</Catalyst> was actually returning the first error.  This has
+been fixed but there is a small chance it could be a breaking issue for you.  If this gives
+you trouble changing to C<shift_errors> is the easiest workaround (although that does
+modify the error stack so if you are relying on that not being changed you should try something
+like @{$c->errors}[-1] instead.  Since this method is relatively new and the cases when the
+error stack actually has more than one error in it, we feel the exposure is very low, but bug
+reports are very welcomed.
+
 =head1 Upgrading to Catalyst 5.90090
 
 L<Catalyst::Utils> has a new method 'inject_component' which works the same as the method of
@@ -63,16 +73,25 @@ In L<CatalystX::ComponentsFromConfig>:
 
     MyApp->config(
       'Model::MyClass' => {
-          class => 
+          class => 'MyClass',
+          args => { %args },
 
       });
 
-<Model::MyClass>
- class My::Class
- <args>
-  some param
- </args>
-</Model::MyClass>
+and now in core:
+
+    MyApp->config(
+      inject_components => {
+        'Model::MyClass' => { from_component => 'My::Class' },
+      },
+      'Model::MyClass' => {
+        %args
+      },
+    );
+
+Although the cored behavior requires more code, its better separates concerns
+as well as plays more into core Catalyst expections of how configuration shoul
+look.
 
 Also we added a new develop console mode only warning when you call a component
 with arguments that don't expect or do anything meaningful with those args.  Its