Fixed flow logic (I hope)