ajuste no biome
This commit is contained in:
parent
fa33b5c23f
commit
eb88195f6a
14 changed files with 93 additions and 78 deletions
|
|
@ -14,9 +14,9 @@ export type tipoLokiObjeto = {
|
|||
|
||||
export const postLogger = async ({
|
||||
objeto,
|
||||
}: { objeto: tipoLokiObjeto }): Promise<
|
||||
[objeto: tipoLokiObjeto, erro?: string]
|
||||
> => {
|
||||
}: {
|
||||
objeto: tipoLokiObjeto
|
||||
}): Promise<[objeto: tipoLokiObjeto, erro?: string]> => {
|
||||
const response = await crossFetch(`${LOKI_BASE_URL}${LOKI_ENDPOINT}`, {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
|
|
@ -24,9 +24,8 @@ export const postLogger = async ({
|
|||
}).catch((a) => a)
|
||||
if (!response.ok) {
|
||||
return [objeto, `Erro ${response.status}: ${await response?.text?.()}`]
|
||||
} else {
|
||||
return [objeto]
|
||||
}
|
||||
return [objeto]
|
||||
}
|
||||
|
||||
let cwd = ""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue