Avoid unecessary project refresh on branch-switch

Fixes #1597
This commit is contained in:
Nick O'Leary 2018-01-31 23:16:38 +00:00
parent 528db67c34
commit 3d8d6953ec
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 7 additions and 5 deletions

View File

@ -650,10 +650,10 @@ RED.sidebar.versionControl = (function() {
// done(error,null);
},
200: function(data) {
RED.projects.refresh(function() {
closeBranchBox(function() {
spinner.remove();
});
// Changing branch will trigger a runtime event
// that leads to a project refresh.
closeBranchBox(function() {
spinner.remove();
});
},
400: {
@ -672,7 +672,9 @@ RED.sidebar.versionControl = (function() {
},
}
},body).always(function(){
RED.deploy.setDeployInflight(false);
setTimeout(function() {
RED.deploy.setDeployInflight(false);
},500);
});
}
});