Closed ndibek closed 10 years ago
I can confirm that this fixed this same problem for me. Is there a reason this change is not part of the official file now?
@douglasduteil
Could we please get this merged with the official source? This fix is really good, I ran some tests and this literally cut the plugin's memory consumption by half. I have made the modification to my own file and it works wonderfully, I've noticed no side effects and only the two lines proposed have to change.
Immediately sry for the wait. Thanks @ndibek @ciel
That is okay, I am just excited it got added. I am loving this project, so I actually just submitted my own pull request!
Watch handler is called twice this causes onload to get called twice which can cause problems. According to https://docs.angularjs.org/api/ng/type/$rootScope.Scope#methods_$watch we can add a check to only handle changes.
Added check to watch of attrs.uiAce so that the handler only gets called when something actually changes