Skip to content

Commit 32b2ac1

Browse files
author
harvey_xiang
committed
feat: update mcp
1 parent d74e628 commit 32b2ac1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/memos/utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import time
22

3+
from memos import settings
34
from memos.log import get_logger
45

56

@@ -13,7 +14,8 @@ def wrapper(*args, **kwargs):
1314
start = time.perf_counter()
1415
result = func(*args, **kwargs)
1516
elapsed = time.perf_counter() - start
16-
logger.info(f"[TIMER] {func.__name__} took {elapsed:.2f} s")
17+
if settings.DEBUG:
18+
logger.info(f"[TIMER] {func.__name__} took {elapsed:.2f} s")
1719
return result
1820

1921
return wrapper

0 commit comments

Comments
 (0)