Fix: fix task error

fix remove function, remove $index