From a396ed84ead4d55a6edd57731205db6274740439 Mon Sep 17 00:00:00 2001 From: Jules Date: Sat, 9 Apr 2016 01:00:57 -0400 Subject: repair cc if values become weird --- js/lex.js | 2 ++ 1 file changed, 2 insertions(+) (limited to 'js') diff --git a/js/lex.js b/js/lex.js index 308f666..20c801b 100644 --- a/js/lex.js +++ b/js/lex.js @@ -14,6 +14,8 @@ function Lex (x,y) { this.focused = false } Lex.prototype.build = function(){ + if (isNaN(this.bg) || this.bg == Infinity || this.bg == -Infinity) this.bg = colors.black + if (isNaN(this.fg) || this.fg == Infinity || this.fg == -Infinity) this.fg = colors.black this.span.className = this.css() this.span.innerHTML = this.html() } -- cgit v1.2.3-70-g09d2