mirror of
https://github.com/DarthAffe/RGB.NET.git
synced 2025-12-12 17:48:31 +00:00
Fixed potential endless-loop in id generation
This commit is contained in:
parent
8adeaab54d
commit
a2646ae43c
@ -43,7 +43,7 @@ public static class IdGenerator
|
||||
{
|
||||
mappedId = id;
|
||||
int mappingCounter = 1;
|
||||
while (_registeredIds.Contains(id))
|
||||
while (_registeredIds.Contains(mappedId))
|
||||
mappedId = $"{id} ({++mappingCounter})";
|
||||
|
||||
_registeredIds.Add(mappedId);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user