Skip to content

Commit 0be6da0

Browse files
committed
Fixed #246
1 parent 658e6f2 commit 0be6da0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/src/main/java/xyz/gianlu/librespot/ZeroconfServer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,9 +426,9 @@ private static class Inner {
426426
Inner(@NotNull Connect.DeviceType deviceType, @NotNull String deviceName, @Nullable String deviceId, @NotNull String preferredLocale, @NotNull Session.Configuration conf) {
427427
this.deviceType = deviceType;
428428
this.deviceName = deviceName;
429-
this.deviceId = deviceId;
430429
this.preferredLocale = preferredLocale;
431430
this.conf = conf;
431+
this.deviceId = (deviceId == null || deviceId.isEmpty()) ? Utils.randomHexString(random, 40).toLowerCase() : deviceId;
432432
}
433433
}
434434

0 commit comments

Comments
 (0)