Pman.js
authorAlan Knowles <alan@akbkhome.com>
Fri, 4 Nov 2011 03:39:49 +0000 (11:39 +0800)
committerAlan Knowles <alan@akbkhome.com>
Fri, 4 Nov 2011 03:39:49 +0000 (11:39 +0800)
Pman.js

diff --git a/Pman.js b/Pman.js
index d11a6b2..4af9993 100644 (file)
--- a/Pman.js
+++ b/Pman.js
@@ -822,8 +822,6 @@ Pman = new Roo.Document(
         
         
         
-        
-        
         if (!obj.parent) {
             if (obj.parent === false) {
                 //console.log('skip module (no parent)' + obj.modkey);
@@ -910,6 +908,10 @@ Pman = new Roo.Document(
             if (typeof(mod) == 'function') {
                 mod();
                 
+            } else  if (typeof(mod.region) == 'undefined') {
+                Roo.log("Module does not have region defined, skipping");
+                Roo.log(mod);
+                
             } else  if (mod.parent.layout && !mod.module.disabled) {
                 // honour permname setings..
                 if (mod.permname && mod.permname.length) {
@@ -918,9 +920,7 @@ Pman = new Roo.Document(
                     }
                 } else {
                     mod.module.add(mod.parent.layout, mod.region);    
-                }
-                    
-                 
+                } 
             }