add ->{original}{default_value} when rewriting to current_timestamp
[dbsrgits/DBIx-Class-Schema-Loader.git] / lib / DBIx / Class / Schema / Loader / DBI / Pg.pm
index 52c7489..e92fbaf 100644 (file)
@@ -231,6 +231,9 @@ EOF
         if ((eval { lc ${ $info->{default_value} } }||'') eq 'now()') {
             # do not use a ref to a constant, that breaks Data::Dump output
             ${$info->{default_value}} = 'current_timestamp';
+
+            my $now = 'now()';
+            $info->{original}{default_value} = \$now;
         }
     }