From 6b446d77ba31e5a4f5905689ef2345ed40b35296 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tomas=20Wenstr=C3=B6m?= Date: Sun, 11 Aug 2019 12:59:34 +0200 Subject: [PATCH] Bugfix - group regex --- src/kaka/cakelight/Console.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/kaka/cakelight/Console.java b/src/kaka/cakelight/Console.java index cd48f49..faa7054 100644 --- a/src/kaka/cakelight/Console.java +++ b/src/kaka/cakelight/Console.java @@ -47,11 +47,11 @@ public class Console extends Thread { ); cakelight.setMode(new SingleColorMode(c)); System.out.println("setting color to " + c); - } else if (input.matches("g|gamma\\s+[0-9.]+")) { + } else if (input.matches("(g|gamma)\\s+[0-9.]+")) { String[] split = input.split("\\s+"); config.gamma = Double.parseDouble(split[1]); System.out.println("setting gamma to " + config.gamma); - } else if (input.matches("s|saturation\\s+[0-9.]+")) { + } else if (input.matches("(s|saturation)\\s+[0-9.]+")) { String[] split = input.split("\\s+"); config.video.saturation = Double.parseDouble(split[1]); System.out.println("setting saturation to " + config.video.saturation); -- 2.11.0