fix: use default branch

This commit is contained in:
Rongjian Zhang 2019-09-13 23:01:30 +08:00
parent bf3f077efa
commit a2cb2fb9e9
2 changed files with 6 additions and 2 deletions

View File

@ -22,7 +22,7 @@ class ObjectScreen extends StatelessWidget {
ObjectScreen({
@required this.owner,
@required this.name,
this.branch = 'master',
@required this.branch,
this.paths = const [],
this.type = 'tree',
});

View File

@ -240,7 +240,11 @@ class RepoScreen extends StatelessWidget {
),
],
),
screenBuilder: (_) => ObjectScreen(owner: owner, name: name),
screenBuilder: (_) => ObjectScreen(
owner: owner,
name: name,
branch: payload['defaultBranchRef']['name'], // FIXME: null
),
),
TableViewItem(
leftWidget: Icon(Octicons.issue_opened, size: 20),