Skip to content

Commit cfb52ea

Browse files
committed
wip
1 parent 81fd553 commit cfb52ea

File tree

2 files changed

+4
-14
lines changed

2 files changed

+4
-14
lines changed

packages/signals/signals/src/lib/logger/index.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,9 @@ import { parseSignalsLoggingAdvancedQueryString } from '../../core/debug-mode'
22
import { DebugStorage } from '../storage/debug-storage'
33

44
class Logger {
5-
private storageType = 'sessionStorage' as const
65
private static advancedLogging = 'segment_signals_logging_advanced'
76

8-
storage = new DebugStorage(this.storageType)
7+
storage = new DebugStorage('sessionStorage')
98
constructor() {
109
const val = parseSignalsLoggingAdvancedQueryString()
1110
if (typeof val === 'boolean') {

packages/signals/signals/src/plugin/signals-plugin.ts

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -87,18 +87,9 @@ export class SignalsPlugin implements Plugin, SignalsAugmentedFunctionality {
8787
}
8888

8989
/**
90-
* Enable redaction and disable ingestion of signals.
90+
* Enable redaction and disable ingestion of signals. Also, logs signals to the console.
9191
*/
92-
debug() {
93-
this.signals.debug()
94-
}
95-
96-
/**
97-
* Log signals to the console.
98-
*/
99-
enableDebugLogging(
100-
...args: Parameters<typeof this.signals.enableDebugLogging>
101-
) {
102-
this.signals.enableDebugLogging(...args)
92+
debug(boolean = true): void {
93+
this.signals.debug(boolean)
10394
}
10495
}

0 commit comments

Comments
 (0)