working towards completing the general flow