Skip to content

Commit e6d7818

Browse files
committed
refactor: ! Add IQuery.warn() - for visibility of output
1 parent 7b65791 commit e6d7818

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

src/IQuery.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,14 @@ export interface IQuery {
8585
* @param objects
8686
*/
8787
debug(message: string, objects?: any): void;
88+
89+
/**
90+
* Write a warn log message.
91+
*
92+
* This is provided to allow the query rendering code to log progress on the rendering,
93+
* including meaningful information about the query being rendered.
94+
* @param message
95+
* @param objects
96+
*/
97+
warn(message: string, objects?: any): void;
8898
}

src/Query/Query.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -458,4 +458,8 @@ ${statement.explainStatement(' ')}
458458
public debug(message: string, objects?: any): void {
459459
this.logger.debugWithId(this._queryId, `"${this.filePath}": ${message}`, objects);
460460
}
461+
462+
public warn(message: string, objects?: any): void {
463+
this.logger.warnWithId(this._queryId, `"${this.filePath}": ${message}`, objects);
464+
}
461465
}

0 commit comments

Comments
 (0)