Skip to content

Commit f3361bf

Browse files
authored
Merge pull request #31 from Linusp/dev
Optimized `InoreaderClient.fetch_articles` and release v0.7.1
2 parents 0c8a076 + 05e3f5b commit f3361bf

File tree

3 files changed

+12
-3
lines changed

3 files changed

+12
-3
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# CHANGELOG
22

3+
## v0.7.1
4+
5+
Changed
6+
7+
- Optimized `InoreaderClient.fetch_articles` for less API calls when tags are specified
8+
39
## v0.7.0
410

511
Removed

inoreader/client.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,11 @@ def fetch_articles(
166166
):
167167
self.check_token()
168168

169-
if not stream_id and folder:
170-
stream_id = self.GENERAL_TAG_TEMPLATE.format(folder)
169+
if not stream_id:
170+
if folder:
171+
stream_id = self.GENERAL_TAG_TEMPLATE.format(folder)
172+
elif tags:
173+
stream_id = self.GENERAL_TAG_TEMPLATE.format(tags[0])
171174

172175
params = {"stream_id": stream_id, "n": n, "c": str(uuid4())}
173176
if unread:

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "python-inoreader"
3-
version = "0.7.0"
3+
version = "0.7.1"
44
description = "Python wrapper of Inoreader API"
55
authors = [
66
{name = "Linusp", email = "linusp1024@gmail.com"},

0 commit comments

Comments
 (0)