mirror of https://github.com/embarklabs/embark.git
if not enabled return original object
This commit is contained in:
parent
5f94848d05
commit
f15e36a7c6
|
@ -20,6 +20,7 @@ class StructLog {
|
||||||
}
|
}
|
||||||
|
|
||||||
tagObject(ogObject, logId) {
|
tagObject(ogObject, logId) {
|
||||||
|
if (!this.isEnabled()) return ogObject;
|
||||||
let newObject = Object.assign({}, ogObject, { logId });
|
let newObject = Object.assign({}, ogObject, { logId });
|
||||||
Object.setPrototypeOf(newObject, ogObject);
|
Object.setPrototypeOf(newObject, ogObject);
|
||||||
return newObject;
|
return newObject;
|
||||||
|
|
Loading…
Reference in New Issue