diff --git a/configs/properties.ts b/configs/properties.ts index df68242..1bf9c56 100644 --- a/configs/properties.ts +++ b/configs/properties.ts @@ -15,16 +15,6 @@ export const FOOTER_LINKS = [ export const MIN_USER_NAME_LENGTH = 3; -export const SERVER_PATHES = { - routes: { - storage: '/storage/', - }, - api: { - public: {}, - user: {}, - }, -}; - export const COOKIE_NAMES = { refreshToken: 'NUXT3_BLOG_RT', userIdentity: 'NUXT3_BLOG_UI', @@ -46,4 +36,4 @@ export const ARTICLE_TOPICS = [ { name: 'web', title: 'WEB', emoji: '👾' }, ]; -export const ARTICLE_KEYWORDS = ['api', 'architecture', 'design'] as const; +export const ARTICLE_KEYWORDS = ['api', 'architecture', 'design', 'fundamentals', 'perfomance', 'refactoring'] as const; diff --git a/server/routes/storage/[...].ts b/server/routes/storage/[...].ts index 481ade6..6737fb9 100644 --- a/server/routes/storage/[...].ts +++ b/server/routes/storage/[...].ts @@ -1,13 +1,12 @@ // eslint-disable-next-line import/named import { v2 as cloudinary } from 'cloudinary'; -import { SERVER_PATHES } from '~/configs/properties'; export default defineEventHandler((event) => { let assetUrl; try { const { req } = event.node; const { pathname, searchParams } = new URL(req.url ?? '', `http://${req.headers.host}`); - const path = pathname.replace(SERVER_PATHES.routes.storage, ''); + const path = pathname.replace('/storage/', ''); assetUrl = cloudinary.url(path, { quality: 'auto', fetch_format: 'auto',