fix regex

This commit is contained in:
2024-05-19 19:24:16 +02:00
parent a9e981baa0
commit c52e92e3ce
2 changed files with 2 additions and 2 deletions

View File

@@ -2,7 +2,7 @@ import log from "loglevel";
import { apply, reg } from "loglevel-plugin-prefix"; import { apply, reg } from "loglevel-plugin-prefix";
export function initLogger() { export function initLogger() {
log.setLevel(import.meta.env.VITE_LOG_LEVEL ?? 'info'); log.setLevel(import.meta.env.VITE_LOG_LEVEL);
reg(log); reg(log);
apply(log, {template: '[%t] %l:'}); apply(log, {template: '[%t] %l:'});
} }

View File

@@ -33,7 +33,7 @@ marbasAxiosInstance.interceptors.response.use(async r => {
let results = r.data?.results; let results = r.data?.results;
if (!next.startsWith(import.meta.env.VITE_MARBAS_URL)) { // FIME remove once the API is fixed if (!next.startsWith(import.meta.env.VITE_MARBAS_URL)) { // FIME remove once the API is fixed
next = import.meta.env.VITE_MARBAS_URL + next.replace(/http(s)?:\/\/[^/]+/g, ''); next = import.meta.env.VITE_MARBAS_URL + next.replace(/http(s)?:\/\/[^/]+\//g, '');
} }
if (next) { if (next) {
results = results.concat((await marbasAxiosInstance.request({ results = results.concat((await marbasAxiosInstance.request({