Commit d42c1b2
authored
fix(config): sanitize config failing on array with multiple problems (@fehmer) (monkeytypegame#7221)
Sanitize throws error if an object contains an array with 1) an invalid
value and 2) too few items. The list of problems contains the path to
the array twice and tries to remove the invalid element from the already
deleted array.
Config object:
```json
"customPolyglot": [
"japanese"
]
```1 parent b9dd150 commit d42c1b2
File tree
2 files changed
+16
-1
lines changed- frontend
- __tests__/utils
- src/ts/utils
2 files changed
+16
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
151 | 151 | | |
152 | 152 | | |
153 | 153 | | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
154 | 166 | | |
155 | 167 | | |
156 | 168 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
7 | 10 | | |
8 | 11 | | |
9 | 12 | | |
| |||
0 commit comments