Typescript Remove Item From Array Based On Condition