More work on logic flow