From d705a60f27403392559cd64e0674ec75118de042 Mon Sep 17 00:00:00 2001 From: Keith Siilats Date: Mon, 28 May 2018 19:15:58 -0400 Subject: allow - in token to use UDID from Xcode as token --- src/org/traccar/model/User.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/org/traccar/model') diff --git a/src/org/traccar/model/User.java b/src/org/traccar/model/User.java index 99e12a072..976b6aac0 100644 --- a/src/org/traccar/model/User.java +++ b/src/org/traccar/model/User.java @@ -203,7 +203,7 @@ public class User extends ExtendedModel { public void setToken(String token) { if (token != null && !token.isEmpty()) { - if (!token.matches("^[a-zA-Z0-9]{16,}$")) { + if (!token.matches("^[a-zA-Z0-9-]{16,}$")) { throw new IllegalArgumentException("Illegal token"); } this.token = token; -- cgit v1.2.3