Skip to content

Bug: [BUG] #333

@KDean-Dolphin

Description

@KDean-Dolphin

Describe the bug

Changing hideLogPositionForProduction at runtime has no effect.

To Reproduce

This works as expected:

// Create a logger at Info level and hide from production.
const logger = new Logger({ minLevel: 3, hideLogPositionForProduction: true });

// Log a message.
logger.info("Whatever.");

This doesn't:

// Create a logger at Info level.
const logger = new Logger({ minLevel: 3 });

// Hide from production.
logger.settings.hideLogPositionForProduction = true;

// Log a message.
logger.info("Whatever.");

Expected behavior

No source or line number information. True for the first, not true for the second.

Node.js Version

v24.11.0

OS incl. Version

macOS 26.2 (25C56)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions