Skip to content

Commit a299a5b

Browse files
committed
refactor(model): simplify formData option
1 parent 1c612b5 commit a299a5b

File tree

1 file changed

+2
-24
lines changed

1 file changed

+2
-24
lines changed

src/Model.js

Lines changed: 2 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -42,30 +42,8 @@ export default class Model extends StaticModel {
4242
return this
4343
}
4444

45-
formData(options = {}) {
46-
const defaultOptions = {
47-
/**
48-
* Include array indices in FormData keys
49-
*/
50-
indices: false,
51-
52-
/**
53-
* Treat null values like undefined values and ignore them
54-
*/
55-
nullsAsUndefineds: false,
56-
57-
/**
58-
* Convert true or false to 1 or 0 respectively
59-
*/
60-
booleansAsIntegers: false,
61-
62-
/**
63-
* Store arrays even if they're empty
64-
*/
65-
allowEmptyArrays: false,
66-
}
67-
68-
return { ...defaultOptions, ...options }
45+
formData() {
46+
return {}
6947
}
7048

7149
resource() {

0 commit comments

Comments
 (0)