Filter out invalid configurations
Remove unnecessary code
Clone items list instead of applying it to the working copy directly