From 34b4ee2688de6b37f6727b27fd972aa9932b4a40 Mon Sep 17 00:00:00 2001 From: manetta Date: Thu, 4 Apr 2019 18:56:57 +0200 Subject: [PATCH] undo cat check --- 08/cnn/cnn.css | 4 ++-- 08/cnn/cnn.js | 6 ------ 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/08/cnn/cnn.css b/08/cnn/cnn.css index fc30c53..185d06c 100644 --- a/08/cnn/cnn.css +++ b/08/cnn/cnn.css @@ -16,8 +16,8 @@ body { vertical-align: top; padding: 5px; font-size: 14px; - background-image: -webkit-gradient(linear, left top, left bottom, from(#02b38d), to(#07d2c4)); - /*background-image: -webkit-gradient(linear, left top, left bottom, from(yellow), to(gold));*/ + /*background-image: -webkit-gradient(linear, left top, left bottom, from(#02b38d), to(#07d2c4));*/ + background-image: -webkit-gradient(linear, left top, left bottom, from(yellow), to(gold)); } #cnn .button_container { display: inline-block; diff --git a/08/cnn/cnn.js b/08/cnn/cnn.js index 3ac438b..493102f 100644 --- a/08/cnn/cnn.js +++ b/08/cnn/cnn.js @@ -28,12 +28,6 @@ // Find categories that this page is part of var categories = findCategories(data); - if ( categories.length > 0 && categories.length < 2){ - //if we have only one category we add another one at random - var keys = Object.keys(data) - keys.splice(categories[1], 1) - categories.push(keys[Math.floor(Math.random() * keys.length)]) - } // Select a pseudo-randomised category for buttonA var buttonA = categories[Math.floor(Math.random() * categories.length)];