this is what I have tried but it is not work?
function updateRecords(records, id, prop, value) {
if(records[id][prop] == “”){
delete records[id];
}
if(records[id] != “tracks” && records[id][prop] != “”){
return records[id][prop] = records[id];
}
if(records[id] == “tracks” && records[id][prop] != “”){
records[id].tracks=[“”];
return records[id][prop].tracks;
}
return records;
}
according to what i was writing does not work? i want you to help me? if cause by my mistake you can handle it for the sake of improving the knowledge.
I might suggest you go back a few challenges and make sure you understand objects and how to work with them.
When you come back to this challenge read the requirements carefully and make sure you understand the data you are working with.
How the object(s) are structured and what the function parameters are. Look at the tests in the bottom left to see the different values the function is supplied with.