File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 27
27
enableLogging = false
28
28
29
29
template log (str: varargs [string , `$`]) =
30
- if enableLogging: echo " [sessions] " , str.join (" " )
30
+ echo " [sessions] " , str.join (" " )
31
31
32
32
proc snowflakeToEpoch (flake: int64 ): int64 =
33
33
int64 (((flake shr 22 ) + 1288834974657 ) div 1000 )
@@ -188,15 +188,15 @@ proc initSessionPool*(cfg: Config; path: string) =
188
188
enableLogging = cfg.enableDebug
189
189
190
190
if path.endsWith (" .json" ):
191
- echo " [sessions] ERROR: .json is not supported, the file must be a valid JSONL file ending in .jsonl"
191
+ log " ERROR: .json is not supported, the file must be a valid JSONL file ending in .jsonl"
192
192
quit 1
193
193
194
194
if not fileExists (path):
195
- echo " [sessions] ERROR: " , path, " not found. This file is required to authenticate API requests."
195
+ log " ERROR: " , path, " not found. This file is required to authenticate API requests."
196
196
quit 1
197
197
198
- log " Parsing JSONL account sessions file: " , path
198
+ log " parsing JSONL account sessions file: " , path
199
199
for line in path.lines:
200
200
sessionPool.add parseSession (line)
201
201
202
- log " Successfully added " , sessionPool.len, " valid account sessions. "
202
+ log " successfully added " , sessionPool.len, " valid account sessions"
You can’t perform that action at this time.
0 commit comments