dbgenerate.js
authorAlan Knowles <alan@akbkhome.com>
Mon, 27 Feb 2012 05:06:17 +0000 (13:06 +0800)
committerAlan Knowles <alan@akbkhome.com>
Mon, 27 Feb 2012 05:06:17 +0000 (13:06 +0800)
dbgenerate.js

index 0b86503..e105408 100644 (file)
@@ -300,6 +300,11 @@ tables.forEach(function(table) {
     //print(JSON.stringify(schema, null,4));    Seed.quit();
     
     schema.forEach(function(e)  {
+        
+        if (!e.Type) {
+            print(JSON.stringify(e, null,4));    Seed.quit();
+        }
+        
         var type = e.Type.match(/([^(]+)\(([^\)]+)\)/);
         var row  = { }; 
         if (type) {