Every action has a consequence, and for Israel, their 'iniquity' had reached a breaking point. Edom's cruelty only sealed their own doom.
The phrase "in the time that their iniquity had an end" refers to the moment when Israel's sin had reached its full measure, leading to the final judgment and the destruction of Jerusalem by the Babylonians.
Instead of recognizing this as a consequence of sin, Edom saw it as an opportunity for malice. Their own actions, however, were compounding their guilt. By exulting in and contributing to the suffering of God's people during their judgment, Edom was not only acting cruelly but was also adding to their own "iniquity" that would eventually lead to their own downfall.
This highlights a crucial theological point: while God uses even wicked nations to enact judgment, those who actively participate in cruelty and hatred towards His people during their chastisement face their own divine reckoning.