mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-06 21:45:43 +01:00
Fixed issue with branch selector
This commit is contained in:
@@ -79,6 +79,12 @@ class BranchSelector extends React.Component<Props, State> {
|
||||
|
||||
branchSelected = (branchName: string) => {
|
||||
const { branches, selected } = this.props;
|
||||
|
||||
if (!branchName) {
|
||||
this.setState({ selectedBranch: undefined });
|
||||
selected(undefined);
|
||||
return;
|
||||
}
|
||||
const branch = branches.find(b => b.name === branchName);
|
||||
|
||||
selected(branch);
|
||||
|
||||
Reference in New Issue
Block a user