fix(editor): Fix UI urls when hosted behind a path prefix (#8198)

fixes #8061
This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™ 2024-01-03 11:37:01 +01:00 committed by GitHub
parent 66460f66b0
commit 5c078f1b3d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,8 +7,7 @@ const { VUE_APP_URL_BASE_API } = import.meta.env;
export const useRootStore = defineStore(STORES.ROOT, {
state: (): RootState => ({
baseUrl:
VUE_APP_URL_BASE_API ?? (window.BASE_PATH === '/{{BASE_PATH}}/' ? '/' : window.BASE_PATH),
baseUrl: VUE_APP_URL_BASE_API ?? window.BASE_PATH,
restEndpoint:
!window.REST_ENDPOINT || window.REST_ENDPOINT === '{{REST_ENDPOINT}}'
? 'rest'