From c0aba691859793c07e9d17c7494af36013f046c0 Mon Sep 17 00:00:00 2001
From: Christian Heller <c.heller@plomlompom.de>
Date: Tue, 1 Dec 2020 06:37:47 +0100
Subject: [PATCH] Fix color setting bug.

---
 rogue_chat.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/rogue_chat.html b/rogue_chat.html
index 17747ff..0a70962 100644
--- a/rogue_chat.html
+++ b/rogue_chat.html
@@ -286,7 +286,7 @@ let terminal = {
   },
   set_random_colors: function() {
       function rand(offset) {
-          return Math.floor(offset + Math.random() * 96).toString(16);
+          return Math.floor(offset + Math.random() * 96).toString(16).padStart(2, '0');
       }
       this.foreground = '#' + rand(159) + rand(159) + rand(159);
       this.background = '#' + rand(0) + rand(0) + rand(0);
-- 
2.30.2