Skip to content

Commit 760bfe8

Browse files
committed
chore: fix prettier
1 parent cc7181b commit 760bfe8

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

src/utils/optimizeTop.ts

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,21 +21,21 @@ export function optimizeTop<T extends { index: number; x: number; y: number }>(
2121
) {
2222
currentIndex--;
2323
} else if (
24-
y[currentIndex + 1] >= y[currentIndex] &&
25-
y[currentIndex + 1] >= y[currentIndex + 2]
26-
) {
27-
currentIndex++;
28-
} else if (
29-
y[currentIndex - 2] >= y[currentIndex - 3] &&
30-
y[currentIndex - 2] >= y[currentIndex - 1]
31-
) {
32-
currentIndex -= 2;
33-
} else if (
34-
y[currentIndex + 2] >= y[currentIndex + 1] &&
35-
y[currentIndex + 2] >= y[currentIndex + 3]
36-
) {
37-
currentIndex += 2;
38-
}
24+
y[currentIndex + 1] >= y[currentIndex] &&
25+
y[currentIndex + 1] >= y[currentIndex + 2]
26+
) {
27+
currentIndex++;
28+
} else if (
29+
y[currentIndex - 2] >= y[currentIndex - 3] &&
30+
y[currentIndex - 2] >= y[currentIndex - 1]
31+
) {
32+
currentIndex -= 2;
33+
} else if (
34+
y[currentIndex + 2] >= y[currentIndex + 1] &&
35+
y[currentIndex + 2] >= y[currentIndex + 3]
36+
) {
37+
currentIndex += 2;
38+
}
3939
// interpolation to a sin() function
4040
if (
4141
y[currentIndex - 1] > 0 &&

0 commit comments

Comments
 (0)