fix snippet error