Skip to content

Commit

Permalink
fix: changelog for youtube.
Browse files Browse the repository at this point in the history
  • Loading branch information
Aunali321 committed Oct 8, 2022
1 parent ceac838 commit 857a523
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
12 changes: 8 additions & 4 deletions lib/services/github_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ class GithubAPI {
);
final Map<String, String> repoAppPath = {
'com.google.android.youtube': 'youtube',
'app.revanced.android.youtube': 'youtube',
'com.google.android.apps.youtube.music': 'music',
'com.twitter.android': 'twitter',
'com.reddit.frontpage': 'reddit',
Expand Down Expand Up @@ -60,17 +61,20 @@ class GithubAPI {
'/repos/$repoName/commits',
queryParameters: {
'path': path,
'per_page': 3,
'since': since.toIso8601String(),
},
options: _cacheOptions,
);
List<dynamic> commits = response.data;
return commits
.map((commit) =>
(commit['commit']['message'] as String).split('\n')[0])
.map(
(commit) => (commit['commit']['message']).split('\n')[0] +
' - ' +
commit['commit']['author']['name'] +
'\n' as String,
)
.toList();
} on Exception {
} catch (e) {
return List.empty();
}
}
Expand Down
2 changes: 1 addition & 1 deletion lib/services/manager_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ class ManagerAPI {
newCommits = await _githubAPI.getCommits(
packageName,
getPatchesRepo(),
DateTime(2022, 3, 20, 21, 06, 01),
patchDate,
);
}
return newCommits;
Expand Down

0 comments on commit 857a523

Please sign in to comment.