Undo Delete

I am using the dataprocessor and the grid and I am using manual update, when I delete a row in my grid and I run senData(), sometimes a validation on my server side should prevent deletion, this works ok, and the grid displays the error message sent by the server, however the deleted row stays in red and with a line in the middle (strikethrough) , I found on the forum that this should resolve the issue:

But for some reason it does not work for me, this is the code I have (please note that I am getting the error message from the server):

if (action == ‘error’ ) {


Any ideas?

After receiving error status row will ignore setUpdated command.
To resolve issue, you can use

dp.set_invalid(sid, false); //will clear invalid or error status from the row