Merge pull request #1358 from moteus/ring_group_dest_uuid
Fix. Definition of `uuid` function in destination.lua.
This commit is contained in:
commit
f83c7a0032
|
|
@ -39,12 +39,12 @@
|
||||||
|
|
||||||
--define uuid function
|
--define uuid function
|
||||||
local random = math.random;
|
local random = math.random;
|
||||||
local function uuid();
|
local function uuid()
|
||||||
local template ='xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx';
|
local template ='xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx';
|
||||||
return string.gsub(template, '[xy]', function (c)
|
return string.gsub(template, '[xy]', function (c)
|
||||||
local v = (c == 'x') and random(0, 0xf) or random(8, 0xb);
|
local v = (c == 'x') and random(0, 0xf) or random(8, 0xb);
|
||||||
return string.format('%x', v);
|
return string.format('%x', v);
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
--get session variables
|
--get session variables
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue