This question already has an answer here:
I looked over the "your question may already be answered" suggestions box and didn't see anything that fit, but I've been known to miss those before so apologies in advance if this has been asked before (I imagined it must have been, but see nothing).
What is the correct action when something like this happens:
A question is posted to SO.
You see a few missing lines of code that are the problem, so you post an answer saying so.
OP takes the code you've suggested and copies it into their question, along with something like "EDIT: I added this new code and it fixed part of the problem but it still doesn't work."
At this point the answer doesn't fit the question anymore; on the surface the answerer looks pretty stupid for saying "add these lines" when the lines were already in the question (as far as new viewers can tell, anyway). I commented to the OP and asked a follow-up question to see if I could figure out the rest of the problem, but no dice on that just yet and in the meantime the answer is sitting there looking silly.
So, what's the proper procedure in this case? Delete the answer? Rollback the question edit? Leave it sitting there as is until we get to the bottom of the problem? (What if it turns into one of those rabbit-hole questions where the problem keeps changing with every fix?) Just leave it alone and forget about it?