aboutsummaryrefslogtreecommitdiff
path: root/src/crypto/cryptoApi.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/crypto/cryptoApi.ts')
-rw-r--r--src/crypto/cryptoApi.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/crypto/cryptoApi.ts b/src/crypto/cryptoApi.ts
index a4e12c00f..46fe2576e 100644
--- a/src/crypto/cryptoApi.ts
+++ b/src/crypto/cryptoApi.ts
@@ -140,7 +140,7 @@ export class CryptoApi {
*/
private stopped: boolean = false;
- public enableTracing = true;
+ static enableTracing = false;
/**
* Terminate all worker threads.
@@ -148,7 +148,7 @@ export class CryptoApi {
terminateWorkers() {
for (let worker of this.workers) {
if (worker.w) {
- this.enableTracing && console.log("terminating worker");
+ CryptoApi.enableTracing && console.log("terminating worker");
worker.w.terminate();
if (worker.terminationTimerHandle) {
worker.terminationTimerHandle.clear();
@@ -173,7 +173,7 @@ export class CryptoApi {
*/
wake(ws: WorkerState, work: WorkItem): void {
if (this.stopped) {
- this.enableTracing && console.log("not waking, as cryptoApi is stopped");
+ CryptoApi.enableTracing && console.log("not waking, as cryptoApi is stopped");
return;
}
if (ws.currentWorkItem !== null) {
@@ -268,7 +268,7 @@ export class CryptoApi {
return;
}
- this.enableTracing &&
+ CryptoApi.enableTracing &&
console.log(
`rpc ${currentWorkItem.operation} took ${timer.performanceNow() -
currentWorkItem.startTime}ms`,
@@ -299,7 +299,7 @@ export class CryptoApi {
priority: number,
...args: any[]
): Promise<T> {
- this.enableTracing && console.log("cryptoApi: doRpc called");
+ CryptoApi.enableTracing && console.log("cryptoApi: doRpc called");
const p: Promise<T> = new Promise<T>((resolve, reject) => {
const rpcId = this.nextRpcId++;
const workItem: WorkItem = {