revert previous logic