Skip to content

Commit 0def088

Browse files
authored
fix color option for Logger.prettyLogger (#4236)
1 parent b788806 commit 0def088

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/tall-games-draw.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"effect": patch
3+
---
4+
5+
fix color option for Logger.prettyLogger

packages/effect/src/internal/logger.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ const prettyLoggerTty = (options: {
357357
readonly formatDate: (date: Date) => string
358358
}) => {
359359
const processIsBun = typeof process === "object" && "isBun" in process && process.isBun === true
360-
const color = options.colors && processStdoutIsTTY ? withColor : withColorNoop
360+
const color = options.colors ? withColor : withColorNoop
361361
return makeLogger<unknown, void>(
362362
({ annotations, cause, context, date, fiberId, logLevel, message: message_, spans }) => {
363363
const services = FiberRefs.getOrDefault(context, defaultServices.currentServices)

0 commit comments

Comments
 (0)