you can probably simplify this with `return (index >= folders1 && index < folder2) ? 1 : -1`