Fix a bug that wrong object is modified