fixed:adding/removing double set before first/last