Skip to content

Commit

Permalink
Fix another codacy issue (This should fix all)
Browse files Browse the repository at this point in the history
  • Loading branch information
xDec0de committed Sep 1, 2023
1 parent 44de7cc commit fe633d4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/main/java/me/xdec0de/mcutils/java/MCNumbers.java
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,13 @@ public static long[] range(long from, long to) {
if (size > Integer.MAX_VALUE)
size = Integer.MAX_VALUE;
final long[] res = new long[(int)size];
long start = from;
if (from > to)
for (int i = 0; i < res.length; i++)
res[i] = from--;
res[i] = start--;
else
for (int i = 0; i < res.length; i++)
res[i] = from++;
res[i] = start++;
return res;
}

Expand Down

0 comments on commit fe633d4

Please sign in to comment.