Fix next color helper
This commit is contained in:
@@ -36,7 +36,7 @@ angular.module('Application').controller('GraphsController', ['$scope', '$locati
|
||||
var colorIndex = 0;
|
||||
var colors = [ '#2196F3', '#3995b1', '#f0ad4e', '#ff4c4c' ];
|
||||
function getNextColor() {
|
||||
if (colors[colorIndex++]) return colors[colorIndex];
|
||||
if (colors[colorIndex+1]) return colors[colorIndex++];
|
||||
return getRandomColor();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user