added option to remove snippet