Fixing update bugs