```
var dataTablesDefaults = { "lengthMenu": [[10, 20, 50, 100, -1], [10, 20, 50, 100, __('All')]] };
var mine = {lengthMenu: [[1, 2, 5, 10], [1, 2, 5, 10]]};
$.extend(true, {}, dataTablesDefaults, mine);
```
Returns:
```
[
1,
2,
5,
10,
-1
]
```
Which is ugly and not what we want.
We only need to merge the first level. Using the spread operator (...) will do the trick here.
Note that we certainly want to adjust all the other occurrences of
extend for DT's options.
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>