Browse Source
Task/improve log of symbol lookup in Trackinsight data enhancer (#7543)
Improve log level and message
pull/7549/head
Thomas Kaul
3 days ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
6 additions and
8 deletions
-
apps/api/src/services/data-provider/data-enhancer/trackinsight/trackinsight.service.ts
|
|
|
@ -50,12 +50,10 @@ export class TrackinsightDataEnhancerService implements DataEnhancerInterface { |
|
|
|
response: Partial<SymbolProfile>; |
|
|
|
symbol: string; |
|
|
|
}): Promise<Partial<SymbolProfile>> { |
|
|
|
if ( |
|
|
|
!( |
|
|
|
if (!( |
|
|
|
response.assetClass === 'EQUITY' && |
|
|
|
['ETF', 'MUTUALFUND'].includes(response.assetSubClass) |
|
|
|
) |
|
|
|
) { |
|
|
|
)) { |
|
|
|
return response; |
|
|
|
} |
|
|
|
|
|
|
|
@ -214,8 +212,8 @@ export class TrackinsightDataEnhancerService implements DataEnhancerInterface { |
|
|
|
return undefined; |
|
|
|
}) |
|
|
|
.catch(({ message }) => { |
|
|
|
this.logger.error( |
|
|
|
`Failed to search Trackinsight symbol for ${symbol} (${message})` |
|
|
|
this.logger.warn( |
|
|
|
`Could not search Trackinsight symbol for "${symbol}": ${message}` |
|
|
|
); |
|
|
|
|
|
|
|
return undefined; |
|
|
|
|