1
0
mirror of https://github.com/git-touch/git-touch synced 2024-12-16 18:28:51 +01:00

fix: commit without related user

This commit is contained in:
Rongjian Zhang 2019-09-03 14:32:17 +08:00
parent 85e02e84a6
commit b2b6ef4795

View File

@ -33,6 +33,7 @@ class CommitsScreen extends StatelessWidget {
messageHeadline
committedDate
author {
name
email
avatarUrl
user {
@ -82,7 +83,10 @@ class CommitsScreen extends StatelessWidget {
SizedBox(height: 4),
Row(
children: <Widget>[
Text(payload['author']['user']['login'],
Text(
payload['author']['user'] == null
? payload['author']['name']
: payload['author']['user']['login'],
style: TextStyle(
fontWeight: FontWeight.w500, fontSize: 14)),
Text(