refactored some code fixed snippet content empty on changed from list fixed snippet name not updating on list when changed