@@ -343,20 +343,20 @@ export function modelType (node: Node): model.ValueOf {
343
343
namespace : getNameSpace ( node )
344
344
}
345
345
}
346
-
346
+
347
347
if ( Node . isTypeParameterDeclaration ( declaration ) ) {
348
- const parent = declaration . getParent ( ) ;
348
+ const parent = declaration . getParent ( )
349
349
assert (
350
- parent ,
351
- Node . isClassDeclaration ( parent ) ||
352
- Node . isInterfaceDeclaration ( parent ) ||
353
- Node . isTypeAliasDeclaration ( parent ) ,
354
- 'It should be a class, interface, enum, type alias, or type parameter declaration'
350
+ parent ,
351
+ Node . isClassDeclaration ( parent ) ||
352
+ Node . isInterfaceDeclaration ( parent ) ||
353
+ Node . isTypeAliasDeclaration ( parent ) ,
354
+ 'It should be a class, interface, enum, type alias, or type parameter declaration'
355
355
)
356
-
357
- type . type . namespace += '.' + parent . getName ( ) as string ;
356
+
357
+ type . type . namespace = ` ${ type . type . namespace } . ${ parent . getName ( ) as string } `
358
358
}
359
-
359
+
360
360
return type
361
361
}
362
362
}
@@ -489,10 +489,9 @@ export function modelEnumDeclaration (declaration: EnumDeclaration): model.Enum
489
489
export function modelTypeAlias ( declaration : TypeAliasDeclaration ) : model . TypeAlias {
490
490
const type = declaration . getTypeNode ( )
491
491
assert ( declaration , type != null , 'Type alias without a referenced type' )
492
-
493
492
const generics = declaration . getTypeParameters ( ) . map ( typeParameter => ( {
494
493
name : modelGenerics ( typeParameter ) ,
495
- namespace : getNameSpace ( typeParameter ) + '.' + declaration . getName ( ) as string
494
+ namespace : getNameSpace ( typeParameter ) + '.' + declaration . getName ( )
496
495
} ) )
497
496
498
497
const alias = modelType ( type )
0 commit comments