We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0ebd283 commit 61d4fd0Copy full SHA for 61d4fd0
lib/types.js
@@ -14,13 +14,13 @@ var types = {
14
array: function(fields, props) {
15
var move = function(props, i, n) {
16
return function(to) {
17
- if(!canMoveUp(i, n) && !canMoveDown(i, n)) return;
18
- var newList = props.getValue(props.path);
19
- var value = newList.splice(to, 1);
+ if(!canMoveUp(i, n) && !canMoveDown(i, n)) return;
+ var newList = props.getValue(props.path);
+ var value = newList.splice(to, 1);
20
21
- newList.splice(i, 0, value[0]);
22
- props.update(props.path, newList, newList);
23
- };
+ newList.splice(i, 0, value[0]);
+ props.update(props.path, newList, newList);
+ };
24
};
25
var canMoveUp = function(i, n) {
26
return i > 0 && i < n - 1;
0 commit comments