asciidisco / grunt-imagine

Grunt tasks for optimizing & inlining images
MIT License
153 stars 21 forks source link

Task failling with Fatal error: Cannot read property 'staticImagePath' of undefined #61

Closed LaurentGoderre closed 10 years ago

LaurentGoderre commented 10 years ago

Since the change we are getting the following error on all of our build Fatal error: Cannot read property 'staticImagePath' of undefined. I didn't have time to investigate yet

alpadev commented 10 years ago

There is basically a code smell in there.. He is passing in this.data from a function that has probably no context/scope so I guess this may be even undefined. That would even raise an error before when trying to acces on this.data I guess.

asciidisco commented 10 years ago

@LaurentGoderre @alpadev Thanks for the heads up guys, that was a very stupid mistake, fortunately it can be fixed quite easily. Check https://github.com/asciidisco/grunt-imagine/commit/a224b89b0919742cc7108066723cb5d207895f74

I already published 0.3.52 with this commit.

alpadev commented 10 years ago

I see.. catching myself from time to time doing such bad things when coding with JS :)