Roo/mailer/Body.js
authorAlan Knowles <alan@roojs.com>
Wed, 28 Sep 2016 03:43:11 +0000 (11:43 +0800)
committerAlan Knowles <alan@roojs.com>
Wed, 28 Sep 2016 03:43:11 +0000 (11:43 +0800)
Roo/mailer/Body.js

index be22537..e3197cb 100644 (file)
@@ -18,7 +18,7 @@ Roo.mailer = Roo.mailer || {};
  * @param {Object} config The config object
  */
 
-_calls = 0;
+
 
 Roo.mailer.Body  = function(config){
     Roo.mailer.Body.superclass.constructor.call(this, config);
@@ -31,8 +31,9 @@ Roo.mailer.Body  = function(config){
         marginheight : 0,
         offset : 0
     });
-    _calls++;
-    if (_calls > 1) {
+    Roo.mailer.Body._calls++;
+    if (Roo.mailer.Body._calls > 1) {
+        return;
         throw "test";
     }
     
@@ -41,6 +42,8 @@ Roo.mailer.Body  = function(config){
 
 };
 
+Roo.mailer.Body._calls = 0;
+
 Roo.extend(Roo.mailer.Body, Roo.bootstrap.Component,  {