fix small error in sample code