.
This commit is contained in:
parent
25273beaed
commit
d1a7a364bd
1 changed files with 36 additions and 37 deletions
|
|
@ -40,7 +40,7 @@ type tipoLog = {
|
||||||
}
|
}
|
||||||
|
|
||||||
export const logger =
|
export const logger =
|
||||||
({ app, eProducao }: { app: string; eProducao: boolean }) =>
|
({ app: app_e, eProducao }: { app: string; eProducao: boolean }) =>
|
||||||
({ inquilino, usuario }: tipoOpSessao) =>
|
({ inquilino, usuario }: tipoOpSessao) =>
|
||||||
async (
|
async (
|
||||||
level: tipoLevel,
|
level: tipoLevel,
|
||||||
|
|
@ -49,9 +49,8 @@ export const logger =
|
||||||
): Promise<[objeto: object, erro?: string]> => {
|
): Promise<[objeto: object, erro?: string]> => {
|
||||||
let { __filename, detalhes, local } = op_tipoLog || {}
|
let { __filename, detalhes, local } = op_tipoLog || {}
|
||||||
|
|
||||||
if (!eProducao) {
|
const app = `${eProducao ? '' : 'DEV-'}${app_e}`
|
||||||
app = `DEV-${app}`
|
|
||||||
}
|
|
||||||
|
|
||||||
if (cwd && __filename) {
|
if (cwd && __filename) {
|
||||||
__filename = __filename.replace(cwd, "")
|
__filename = __filename.replace(cwd, "")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue