A unit test showed, that the removal regexp was faulty. New version of patch attached.