Skip to content

Commit 3cfe08c

Browse files
author
daffl
committed
Fixed form build error
1 parent 98da463 commit 3cfe08c

File tree

2 files changed

+12
-7
lines changed

2 files changed

+12
-7
lines changed

jquery.dform-0.1.3.min.js

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/dform.js

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,10 +151,15 @@
151151
}, $.dform.options.ajaxFormat);
152152
}
153153
else {
154-
if(!options.type) {
155-
options = $.extend({ "type" : "form" }, options);
154+
if(this.is('form') && (!options.type || options.type == 'form')) {
155+
this.dformAttr(options);
156+
this.runAll(options);
157+
} else {
158+
if(!options.type) {
159+
options = $.extend({ "type" : "form" }, options);
160+
}
161+
this.formElement(options, params);
156162
}
157-
this.formElement(options, params);
158163
}
159164
return this;
160165
},

0 commit comments

Comments
 (0)