removed useless condition
recompiled grid.js
fixed condition
Merge pull request #4 from MaksJS/master

got it right this time