Just to be clear I have no problem with this particular case at all (if anything it may gain my answer more upvotes), but in this question, the original poster edited my answer to include the code they ended up using whereas my original answer only spoke in general terms without any code sample (other than the linked sample in the source documentation).
Is this the most appropriate way to do this, or should the original poster:
- Edit their question to include the code sample
- Add another answer to include the code sample
I have done both 1 and 2 myself but was just wanting to hear any thoughts on what seems most appropriate.
Personally I feel that they should get credit for their contribution, which they will not get if they edit someone else's answer. I suppose in other cases, if the code doesn't work (or worse), then the edited answer may even get downvoted.
I would lean towards 2.) because that lets the solution be rated based on its own merit, not that of the original question.