fix example and by func