only count move if valid
Merge pull request #2 from erikmontes/master

only count move if valid