small bug in supplyradius widget

When sharing a unit which provides supplies to an enemy, the supplyradius widget does not remove the circle for this units.

See screenshots:

[attachment=1]screen013.jpg[/attachment]
Then after sharing the deployed supply truck to the enemy:
[attachment=0]screen014.jpg[/attachment]

This change fixes it:

@@ -562,11 +562,8 @@
 end
 
 function widget:UnitTaken(unitID, unitDefID, unitTeam, newTeam)
-       local _, _, inBuild = GetUnitIsStunned(unitID)
-       if inBuild then
-               widget:UnitCreated(unitID, unitDefID, unitTeam)
-       else
-               widget:UnitFinished(unitID, unitDefID, unitTeam)
+       if (not AreTeamsAllied(unitTeam, newTeam)) then
+               widget:UnitDestroyed(unitID, unitDefID, unitTeam)
        end
 end
 

If you don’t mind a bunch of whitespace changes (I’ve always set up my editor to remove trailing whitespace from every line), then I could commit it myself.

Go ahead and commit. Looks like I misinterpreted UnitTaken.

Done.

Yeah, UnitGiven is ‘units are given to this team’ and UnitTaken is ‘units are taken away from this team’.