refactor(static_reflector): remove unnecessary check.
This commit is contained in:
parent
3a40cb1a85
commit
ba62fe974b
|
@ -331,11 +331,7 @@ export class StaticReflector implements ReflectorReader {
|
|||
let declarationValue =
|
||||
isPresent(moduleMetadata) ? moduleMetadata['metadata'][staticSymbol.name] : null;
|
||||
if (isPresent(declarationValue)) {
|
||||
if (isClassMetadata(declarationValue)) {
|
||||
result = staticSymbol;
|
||||
} else {
|
||||
result = _this.simplify(staticSymbol, declarationValue);
|
||||
}
|
||||
result = _this.simplify(staticSymbol, declarationValue);
|
||||
}
|
||||
return result;
|
||||
case "class":
|
||||
|
@ -391,10 +387,6 @@ export class StaticReflector implements ReflectorReader {
|
|||
}
|
||||
}
|
||||
|
||||
function isClassMetadata(expression: any): boolean {
|
||||
return !isPrimitive(expression) && !isArray(expression) && expression['__symbolic'] == 'class';
|
||||
}
|
||||
|
||||
function mapStringMap(input: {[key: string]: any},
|
||||
transform: (value: any, key: string) => any): {[key: string]: any} {
|
||||
if (isBlank(input)) return {};
|
||||
|
|
Loading…
Reference in New Issue