If your problem was resolved because of something you did, write your own answer explaining what you did to fix it and accept that (you may have to wait before accepting it, depending on how long ago you asked your question).
If it just went away on its own and you have no idea why, then it probably won't provide any value to future readers. You can just delete it, or if you're unable to delete it (e.g. because of multiple/upvoted answers) then flag/close-vote it as "not reproducible" and leave a comment explaining that so people who can vote to close it will know what to do.