[Solved] How to delete item in JSON file


[EDITED]

The delete operator is only for deleting a property from an object. Your config variable contains an array of objects, so delete will not do what you want at all.

You need to iterate through the config array and use something like splice to delete the array items that have the same name, date, and number values as in the request.

This related question might be helpful.

1

solved How to delete item in JSON file