Files
kno-logic-api/utils/array.js
2021-05-19 20:08:04 -04:00

9 lines
234 B
JavaScript

// removeValue(array, item) remove item from the array
function removeValue(array, item) {
var index = array.indexOf(item);
if (index !== -1) {
array.splice(index, 1);
}
}
module.exports.removeValue = removeValue;