bugfix
This commit is contained in:
parent
804d52792a
commit
6dec5bee6a
@ -48,14 +48,16 @@ params:
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
bricks.uuid = function(){
|
bricks.uuid = function(){
|
||||||
return crypto.randomUUID();
|
var d = crypto.randomUUID();
|
||||||
|
var lst = d.split('-');
|
||||||
|
return list.join('');
|
||||||
}
|
}
|
||||||
|
|
||||||
bricks.deviceid = function(appname){
|
bricks.deviceid = function(appname){
|
||||||
var deviceid = appname + 'deviceid';
|
var deviceid = appname + 'deviceid';
|
||||||
var id = localStorage.getItem(deviceid);
|
var id = localStorage.getItem(deviceid);
|
||||||
if (!id){
|
if (!id){
|
||||||
id = crypto.randomUUID();
|
id = bricks.uuid();
|
||||||
localStorage.setItem(deviceid, id);
|
localStorage.setItem(deviceid, id);
|
||||||
}
|
}
|
||||||
return id;
|
return id;
|
||||||
|
Loading…
Reference in New Issue
Block a user