refactor increment-feature function