From a9d7ab9e18689f3309e695d083351f0f5f7225bb Mon Sep 17 00:00:00 2001 From: Bradley Arvin Date: Wed, 28 Oct 2015 13:28:54 -0400 Subject: [PATCH] Fix for #2809 --- src/node/db/AuthorManager.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/node/db/AuthorManager.js b/src/node/db/AuthorManager.js index e0f569ef..3e3b691a 100644 --- a/src/node/db/AuthorManager.js +++ b/src/node/db/AuthorManager.js @@ -127,7 +127,7 @@ exports.createAuthor = function(name, callback) var author = "a." + randomString(16); //create the globalAuthors db entry - var authorObj = {"colorId" : Math.floor(Math.random()*32), "name": name, "timestamp": new Date().getTime()}; + var authorObj = {"colorId" : Math.floor(Math.random()*(exports.getColorPalette().length)), "name": name, "timestamp": new Date().getTime()}; //set the global author db entry db.set("globalAuthor:" + author, authorObj);