1
0
mirror of https://github.com/git-touch/git-touch synced 2024-12-15 01:45:05 +01:00

fix(github): head ref name

closes #116
This commit is contained in:
Rongjian Zhang 2020-10-11 22:12:53 +08:00
parent daf5c8ac45
commit 1d1804fa86
2 changed files with 4 additions and 8 deletions

View File

@ -314,9 +314,7 @@ __typename
login
}
pullRequest {
headRef {
name
}
headRefName
}
}
... on BaseRefForcePushedEvent {
@ -342,9 +340,7 @@ __typename
login
}
pullRequest {
headRef {
name
}
headRefName
}
beforeCommit {
oid

View File

@ -358,7 +358,7 @@ class TimelineItem extends StatelessWidget {
textSpan: TextSpan(children: [
TextSpan(text: ' restored the '),
WidgetSpan(
child: PrimerBranchName(p['pullRequest']['headRef']['name'])),
child: PrimerBranchName(p['pullRequest']['headRefName'])),
TextSpan(text: ' branch')
]),
);
@ -370,7 +370,7 @@ class TimelineItem extends StatelessWidget {
children: [
TextSpan(text: ' force-pushed the '),
WidgetSpan(
child: PrimerBranchName(p['pullRequest']['headRef']['name'])),
child: PrimerBranchName(p['pullRequest']['headRefName'])),
TextSpan(text: ' branch from '),
TextSpan(
text: (p['beforeCommit']['oid'] as String).substring(0, 7),