Browse Source
Feature/improve get symbol data endpoint (#2041)
* Add default value to query parameter
* Update changelog
pull/2043/head
Thomas Kaul
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
7 additions and
1 deletions
-
CHANGELOG.md
-
apps/api/src/app/symbol/symbol.controller.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 |
|
|
|
|
|
|
|
### Added |
|
|
|
|
|
|
|
- Added a default value for the `includeHistoricalData` attribute in the symbol data endpoint |
|
|
|
|
|
|
|
## 1.276.0 - 2023-06-03 |
|
|
|
|
|
|
|
### Added |
|
|
|
|
|
@ -60,7 +60,7 @@ export class SymbolController { |
|
|
|
public async getSymbolData( |
|
|
|
@Param('dataSource') dataSource: DataSource, |
|
|
|
@Param('symbol') symbol: string, |
|
|
|
@Query('includeHistoricalData') includeHistoricalData?: number |
|
|
|
@Query('includeHistoricalData') includeHistoricalData = 0 |
|
|
|
): Promise<SymbolItem> { |
|
|
|
if (!DataSource[dataSource]) { |
|
|
|
throw new HttpException( |
|
|
|