From 3eda9d4ef9a27b79095c46a1a79d4ef6ad95481f Mon Sep 17 00:00:00 2001 From: Albert Vaca Cintora Date: Wed, 5 Mar 2025 15:47:14 +0100 Subject: [PATCH] Allow hyphens in device ids --- src/org/kde/kdeconnect/DeviceInfo.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/org/kde/kdeconnect/DeviceInfo.kt b/src/org/kde/kdeconnect/DeviceInfo.kt index 3844ae58..6f8775be 100644 --- a/src/org/kde/kdeconnect/DeviceInfo.kt +++ b/src/org/kde/kdeconnect/DeviceInfo.kt @@ -110,7 +110,7 @@ class DeviceInfo( isValidDeviceId(getString("deviceId", "")); } - private val DEVICE_ID_REGEX = "^[a-zA-Z0-9_]{32,38}\$".toRegex() + private val DEVICE_ID_REGEX = "^[a-zA-Z0-9_-]{32,38}\$".toRegex() @JvmStatic fun isValidDeviceId(deviceId: String): Boolean = deviceId.matches(DEVICE_ID_REGEX)