Skip to content
This repository was archived by the owner on Feb 18, 2025. It is now read-only.

Commit 9d82908

Browse files
Artiom MisiruArtiom Misiru
authored andcommitted
Update NewsStreamRecord params
1 parent 5b7f98c commit 9d82908

File tree

3 files changed

+17
-7
lines changed

3 files changed

+17
-7
lines changed

CHANGELOG.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
# Release Notes
22

3-
## [6.2.0](https://github.com/timirey/xapi-php/compare/6.0.4..6.0.5) - 2024-12-27
3+
## [6.3.0](https://github.com/timirey/xapi-php/compare/6.3.0..6.2.0) - 2025-01-06
4+
5+
- Add new `topics` param to `NewsStreamRecord`.
6+
7+
## [6.2.0](https://github.com/timirey/xapi-php/compare/6.2.0..6.1.0) - 2024-12-27
48

59
- Add new `QuoteId` and `MarginMode`.
610

7-
## [6.1.0](https://github.com/timirey/xapi-php/compare/6.0.4..6.0.5) - 2024-12-27
11+
## [6.1.0](https://github.com/timirey/xapi-php/compare/6.1.0..6.0.5) - 2024-12-27
812

913
- Remove timeout for stream connection.
1014

src/Responses/Data/NewsStreamRecord.php

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,18 @@
1818
/**
1919
* Constructor for the NewsStreamRecord class.
2020
*
21-
* @param string $body Body of the news.
22-
* @param string $key News key.
23-
* @param integer $time Time of the news.
24-
* @param string $title Title of the news.
21+
* @param string $body Body of the news.
22+
* @param string $key News key.
23+
* @param integer $time Time of the news.
24+
* @param string $title Title of the news.
25+
* @param array $topics Unknown, not documented.
2526
*/
2627
public function __construct(
2728
public string $body,
2829
public string $key,
2930
int $time,
30-
public string $title
31+
public string $title,
32+
public array $topics
3133
) {
3234
$this->time = DateTimeHelper::fromMilliseconds($time);
3335
}

tests/Commands/FetchNewsTest.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@
2121
'data' => [
2222
'body' => '<html>...</html>',
2323
'key' => '1f6da766abd29927aa854823f0105c23',
24+
'topics' => [
25+
'BZEN_REGULAR',
26+
'BZEN_IRREGULAR'
27+
],
2428
'time' => 1262944112000,
2529
'title' => 'Breaking trend',
2630
],

0 commit comments

Comments
 (0)