Fixed execution flow to reflect what's intended