Skip to content

Commit fc8c02a

Browse files
committed
[Web] Fix variable mispell (from value to newValue on add)
1 parent 56065eb commit fc8c02a

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

src/components/JsonAddValue.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ class JsonAddValue extends Component {
6363
const { handleAdd, onlyValue } = this.props;
6464
const { inputRefKey, inputRefValue } = this.state;
6565
const result = {
66-
value: parse(inputRefValue.value),
66+
newValue: parse(inputRefValue.value),
6767
};
6868
// Check if we have the key
6969
if (!onlyValue) {

src/components/JsonArray.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,12 +144,12 @@ class JsonArray extends Component {
144144
};
145145
}
146146

147-
handleAddValueAdd({ value }) {
147+
handleAddValueAdd({ newValue }) {
148148
const { data, keyPath, deep } = this.state;
149149
// Update data
150150
const newData = [
151151
...data,
152-
value,
152+
newValue,
153153
];
154154
this.setState({
155155
data: newData,
@@ -165,7 +165,7 @@ class JsonArray extends Component {
165165
keyPath,
166166
deep,
167167
key: newData.length - 1,
168-
newValue: value,
168+
newValue,
169169
});
170170
}
171171

src/components/JsonObject.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,10 +108,10 @@ class JsonObject extends Component {
108108
});
109109
}
110110

111-
handleAddValueAdd({ key, value }) {
111+
handleAddValueAdd({ key, newValue }) {
112112
const { data, keyPath, deep } = this.state;
113113
// Update data
114-
data[key] = value;
114+
data[key] = newValue;
115115
this.setState({
116116
data,
117117
});
@@ -126,7 +126,7 @@ class JsonObject extends Component {
126126
keyPath,
127127
deep,
128128
key,
129-
value,
129+
newValue,
130130
});
131131
}
132132

0 commit comments

Comments
 (0)