fixes snippet ajax save