One must have sympathy for the flame. How can the flame understand the effect on the moth of their encounter? The flame is unaffected, how would it know the moth's hurt?
***
Munni Begum's La Pila De Saqiya though takes the other view:
Jo jalata hai kisiko, khud bhi jalta hai zaroor,
shamma bhi jalti rahi, parvana jal jane ke baad
What scorches another, surely also burns itself
the flame continued to burn after the moth was burnt