File tree Expand file tree Collapse file tree 1 file changed +10
-12
lines changed
packages/@vuepress/shared-utils/src Expand file tree Collapse file tree 1 file changed +10
-12
lines changed Original file line number Diff line number Diff line change @@ -212,19 +212,17 @@ class ModuleResolver {
212212
213213 if ( req . startsWith ( '@' ) ) {
214214 const pkg = resolveScopePackage ( req )
215- if ( pkg ) {
216- // special handling for default org.
217- if ( this . org && pkg . org === this . org ) {
218- shortcut = pkg . name . startsWith ( `${ this . type } -` )
219- ? pkg . name . slice ( this . typePrefixLength )
220- : pkg . name
221- name = `${ this . scopePrefix } ${ shortcut } `
222- } else {
223- shortcut = this . getShortcut ( pkg . name )
224- name = `@${ pkg . org } /${ this . nonScopePrefix } ${ shortcut } `
225- }
226- shortcut = `@${ pkg . org } /${ shortcut } `
215+ // special handling for default org.
216+ if ( this . org && pkg . org === this . org ) {
217+ shortcut = pkg . name . startsWith ( `${ this . type } -` )
218+ ? pkg . name . slice ( this . typePrefixLength )
219+ : pkg . name
220+ name = `${ this . scopePrefix } ${ shortcut } `
221+ } else {
222+ shortcut = this . getShortcut ( pkg . name )
223+ name = `@${ pkg . org } /${ this . nonScopePrefix } ${ shortcut } `
227224 }
225+ shortcut = `@${ pkg . org } /${ shortcut } `
228226 } else {
229227 shortcut = this . getShortcut ( req )
230228 name = `${ this . nonScopePrefix } ${ shortcut } `
You can’t perform that action at this time.
0 commit comments