fixed redis error in finishTask