Here are three options.
Just make the edit.
Better: make the edit, and leave a comment thanking the other user for drawing your attention to the problem.
Best (in my opinion): make the edit, and also edit into your question a word of thanks to the user for pointing out the problem. This way the user can delete the comment, and no one gets confused about ...
In general, yes, points gained on answers that get deleted because the question gets deleted are lost. Following an undeletion the points are restored.
However, if your post satisfies both of:
has score at least three
was visible1 on the site for at least 60 days prior to deletion
then you get to keep the points.
See this blog post by Josh Heyer, aka ...
Let us create here a community wiki answer to collect resources on this topic elsewhere on the web.
Related posts on TeX Stack Exchange:
What is the status of generating LaTeX from handwriting (i.e., OCR)?
How to convert PDF to (La)TeX?
Image equation to TeX
Possible to Convert Math in Picture into LaTeX? How?
Request to reopen Derive an atlas of Monge patches for a surface in 3D
Since the votes to close (without any comments), I've added links to sources and multiple links to material that motivates the question. I've also clarified what would constitute an answer to the question.