Remove unnecessary resource cloning.