fixup and simplify cycle