handle chunk finished