We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dc171c3 commit f6854edCopy full SHA for f6854ed
1 file changed
lib/form_data.js
@@ -21,6 +21,7 @@ util.inherits(FormData, CombinedStream);
21
* and file uploads to other web applications.
22
*
23
* @constructor
24
+ * @param {Object} options - Properties to be added/overriden for FormData and CombinedStream
25
*/
26
function FormData(options) {
27
if (!(this instanceof FormData)) {
@@ -31,7 +32,12 @@ function FormData(options) {
31
32
this._valueLength = 0;
33
this._valuesToMeasure = [];
34
- Object.assign(this, CombinedStream.create(options));
35
+ CombinedStream.call(this);
36
+
37
+ options = options || {};
38
+ for (var option in options) {
39
+ this[option] = options[option];
40
+ }
41
}
42
43
FormData.LINE_BREAK = '\r\n';
0 commit comments