aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Post.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Post.js b/src/Post.js
index 38eac8e..78be0b6 100644
--- a/src/Post.js
+++ b/src/Post.js
@@ -113,11 +113,11 @@ const Post = ({ index, post, locked, threadId, currentBoard, nightMode }) => {
let rndAvatar, hue;
if (user_id !== "") {
- let i = Math.round(idRng() * avatars.length - 1);
+ let i = Math.round(idRng() * (avatars.length - 1));
rndAvatar = avatars[i];
hue = Math.round(idRng() * 360);
} else {
- let i = Math.round(rng() * avatars.length - 1);
+ let i = Math.round(rng() * (avatars.length - 1));
rndAvatar = avatars[i];
hue = Math.round(rng() * 360);
}