|
|
@ -294,11 +294,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
var utils = {
|
|
|
|
var utils = {
|
|
|
|
generateUUID: function () {
|
|
|
|
generateUUID: function () {
|
|
|
|
|
|
|
|
/* eslint-disable no-bitwise */
|
|
|
|
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
|
|
|
|
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
|
|
|
|
var r = Math.random() * 16 | 0;
|
|
|
|
var r = Math.random() * 16 | 0;
|
|
|
|
var v = c === 'x' ? r : ((r & 0x3) | 0x8);
|
|
|
|
var v = c === 'x' ? r : ((r & 0x3) | 0x8);
|
|
|
|
return v.toString(16);
|
|
|
|
return v.toString(16);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
/* eslint-enable no-bitwise */
|
|
|
|
},
|
|
|
|
},
|
|
|
|
// https://github.com/substack/node-ent/blob/master/index.js
|
|
|
|
// https://github.com/substack/node-ent/blob/master/index.js
|
|
|
|
decodeHTMLEntities: function (html) {
|
|
|
|
decodeHTMLEntities: function (html) {
|
|
|
|