atom / deprecation-cop

Shows a list of deprecated calls
MIT License
12 stars 19 forks source link

Fix empty selectors list in deprecation cop view #48

Closed izuzak closed 9 years ago

izuzak commented 9 years ago

This fixes https://github.com/atom/deprecation-cop/issues/47. As far as I can tell, the problem here was that the variable deprecations from the outer loop was used in the inner loop, and was getting overwritten. This problem was introduced here -- previously the outer loop didn't use a deprecations variable, it just re-fetched the deprecations in every iteration of the loop. Really sorry for not catching this before.

This PR fixes the problem by changing the variable's name in the inner loop so that there's no conflict. We could also use the same approach as before. This just seemed a bit cleaner.

Before:

screen shot 2015-05-19 at 09 36 30

After (correctly lists deprecations in styles.less):

screen shot 2015-05-19 at 09 12 37

cc @kevinsawicki for :eyes:

kevinsawicki commented 9 years ago

:+1: