update sample, remove dead code