Solved unresolved exception when inserting or removing elements
Fixed some instances