finished when
more code for when