Browse Source
Merge branch 'main' into fix-noname-crash
pull/4355/head
Thomas Kaul
2 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with
8 additions and
1 deletions
-
CHANGELOG.md
-
apps/api/src/services/data-provider/data-enhancer/trackinsight/trackinsight.service.ts
|
|
@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 |
|
|
|
|
|
|
|
## Unreleased |
|
|
|
|
|
|
|
### Changed |
|
|
|
|
|
|
|
- Improved the symbol lookup in the _Trackinsight_ data enhancer for asset profile data |
|
|
|
|
|
|
|
### Fixed |
|
|
|
|
|
|
|
- Handled an exception in the benchmark service related to unnamed asset profiles |
|
|
|
|
|
@ -192,7 +192,10 @@ export class TrackinsightDataEnhancerService implements DataEnhancerInterface { |
|
|
|
.then((jsonRes) => { |
|
|
|
if ( |
|
|
|
jsonRes['results']?.['count'] === 1 || |
|
|
|
jsonRes['results']?.['docs']?.[0]?.['ticker'] === symbol |
|
|
|
// Allow exact match
|
|
|
|
jsonRes['results']?.['docs']?.[0]?.['ticker'] === symbol || |
|
|
|
// Allow EXCHANGE:SYMBOL
|
|
|
|
jsonRes['results']?.['docs']?.[0]?.['ticker']?.endsWith(`:${symbol}`) |
|
|
|
) { |
|
|
|
return jsonRes['results']['docs'][0]['ticker']; |
|
|
|
} |
|
|
|