Fixes removal of illegal items