Fix utf8columns loading-order test/code (really just as POC at this point)
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / Row.pm
index 07cfe71..787df86 100644 (file)
@@ -363,7 +363,7 @@ sub insert {
   my $updated_cols = $source->storage->insert(
     $source,
     { $self->get_columns },
-    keys %auto_pri
+    (keys %auto_pri) && $source->storage->can_insert_returning
       ? { returning => [ sort { $auto_pri{$a} <=> $auto_pri{$b} } keys %auto_pri ] }
       : ()
     ,
@@ -484,7 +484,7 @@ the database row can not be constructed (see
 L<significance of primary keys|DBIx::Class::Manual::Intro/The Significance and Importance of Primary Keys>
 for more details).
 
-Also takes an optional hashref of C<< column_name => value> >> pairs
+Also takes an optional hashref of C<< column_name => value >> pairs
 to update on the object first. Be aware that the hashref will be
 passed to C<set_inflated_columns>, which might edit it in place, so
 don't rely on it being the same after a call to C<update>.  If you