first pass RT4 merge, RT#13852
[freeside.git] / rt / etc / upgrade / 4.0.4 / content
diff --git a/rt/etc/upgrade/4.0.4/content b/rt/etc/upgrade/4.0.4/content
new file mode 100644 (file)
index 0000000..fdfcb3e
--- /dev/null
@@ -0,0 +1,16 @@
+@Initial = (
+    sub {
+        use strict;
+        my $templates = RT::Templates->new(RT->SystemUser);
+        $templates->Limit(
+            FIELD => 'Type',
+            OPERATOR => 'IS',
+            VALUE => 'NULL',
+        );
+        while (my $template = $templates->Next) {
+            my ($status, $msg) = $template->SetType('Perl');
+            $RT::Logger->warning( "Couldn't change Type of Template #" . $template->Id . ": $msg" ) unless $status;
+        }
+    },
+);
+