added logic and tests to remove items from custom collections [ci-skip]