remove faulty logic in update code
Merge pull request #9 from mbroadst/fix-update-logic

remove faulty logic in update code