fix database_events
Justin Hunter [Tue, 27 Jul 2010 03:19:28 +0000 (20:19 -0700)]
lib/SQL/Translator/Object/Trigger.pm

index 5e324b5..2bd60d5 100644 (file)
@@ -90,4 +90,12 @@ class SQL::Translator::Object::Trigger extends SQL::Translator::Object {
     }
 
     method is_valid { 1 }
+
+    around BUILDARGS(ClassName $self: @args) {
+        my $args = $self->$orig(@args);
+
+        $args->{_database_events} = delete $args->{database_events} || [];
+
+        return $args;
+     }
 }