File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change 1
1
/*
2
- * jQuery File Upload Plugin 5.21.4
2
+ * jQuery File Upload Plugin 5.22
3
3
* https://github.com/blueimp/jQuery-File-Upload
4
4
*
5
5
* Copyright 2010, Sebastian Tschan
112
112
progressInterval : 100 ,
113
113
// Interval in milliseconds to calculate progress bitrate:
114
114
bitrateInterval : 500 ,
115
+ // By default, uploads are started automatically when adding files:
116
+ autoUpload : true ,
115
117
116
118
// Additional form data to be sent along with the file uploads can be set
117
119
// using this option, which accepts an array of objects with name and
136
138
// handlers using jQuery's Deferred callbacks:
137
139
// data.submit().done(func).fail(func).always(func);
138
140
add : function ( e , data ) {
139
- data . submit ( ) ;
141
+ if ( data . autoUpload || ( data . autoUpload !== false &&
142
+ ( $ ( this ) . data ( 'blueimp-fileupload' ) ||
143
+ $ ( this ) . data ( 'fileupload' ) ) . options . autoUpload ) ) {
144
+ data . submit ( ) ;
145
+ }
140
146
} ,
141
147
142
148
// Other callbacks:
You can’t perform that action at this time.
0 commit comments