File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ function qualifyURL(url) {
2929 return url ;
3030}
3131
32- function isExternal ( url ) {
32+ export function isExternal ( url ) {
3333 url = qualifyURL ( url ) ;
3434 url = new URL ( url ) ;
3535 return url . origin !== location . origin ;
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ import { getPath, isAbsolutePath } from '../router/util';
99import { isMobile , inBrowser } from '../util/env' ;
1010import { isPrimitive } from '../util/core' ;
1111import { scrollActiveSidebar } from '../event/scroll' ;
12+ import { isExternal } from '../fetch' ;
1213import { Compiler } from './compiler' ;
1314import * as tpl from './tpl' ;
1415import { prerenderEmbed } from './embed' ;
@@ -259,10 +260,9 @@ export function initRender(vm) {
259260
260261 if ( config . logo ) {
261262 const isBase64 = / ^ d a t a : i m a g e / . test ( config . logo ) ;
262- const isExternal = / (?: h t t p [ s ] ? : ) ? \/ \/ / . test ( config . logo ) ;
263263 const isRelative = / ^ \. / . test ( config . logo ) ;
264264
265- if ( ! isBase64 && ! isExternal && ! isRelative ) {
265+ if ( ! isBase64 && ! isExternal ( config . logo ) && ! isRelative ) {
266266 config . logo = getPath ( vm . router . getBasePath ( ) , config . logo ) ;
267267 }
268268 }
You can’t perform that action at this time.
0 commit comments