Fixes NullPointerException during update. Fixes #1484

dang, that's a lot of guarding.