finish all func