Browse Source
Feature/improve symbol validation in Yahoo Finance service (#4445)
* Improve symbol validation
* Update changelog
pull/4446/head^2
Thomas Kaul
5 days ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with
8 additions and
0 deletions
-
CHANGELOG.md
-
apps/api/src/services/data-provider/data-enhancer/yahoo-finance/yahoo-finance.service.ts
|
|
@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. |
|
|
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), |
|
|
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). |
|
|
|
|
|
|
|
## Unreleased |
|
|
|
|
|
|
|
### Changed |
|
|
|
|
|
|
|
- Improved the symbol validation in the _Yahoo Finance_ service (get asset profiles) |
|
|
|
|
|
|
|
## 2.146.0 - 2025-03-15 |
|
|
|
|
|
|
|
### Changed |
|
|
|
|
|
@ -170,6 +170,8 @@ export class YahooFinanceDataEnhancerService implements DataEnhancerInterface { |
|
|
|
symbol = quotes[0].symbol; |
|
|
|
} |
|
|
|
} catch {} |
|
|
|
} else if (symbol?.includes('-')) { |
|
|
|
throw new Error(`${symbol} is not valid`); |
|
|
|
} else { |
|
|
|
symbol = this.convertToYahooFinanceSymbol(symbol); |
|
|
|
} |
|
|
|