Commit 64135a3f1e53581109d17fdd30d78438e176fc0e
Committed by
Heitor
1 parent
466a15b4
Exists in
colab
and in
4 other branches
Comments about default branch selection
Showing
1 changed file
with
3 additions
and
1 deletions
Show diff stats
app/assets/javascripts/repository/branch.js.coffee
| ... | ... | @@ -15,10 +15,12 @@ class Repository.Branch |
| 15 | 15 | @request.abort() |
| 16 | 16 | @request = null |
| 17 | 17 | |
| 18 | - # private method | |
| 19 | 18 | fill_options: (options, el) -> |
| 19 | + # FIXME: this works only if master is the default branch | |
| 20 | + # it can be improved by moving it into KalibroProcessor | |
| 20 | 21 | default_branch = "master" |
| 21 | 22 | if default_branch in options |
| 23 | + # Brings the default branch as the first option | |
| 22 | 24 | index = options.indexOf(default_branch) |
| 23 | 25 | options.splice(index, 1) |
| 24 | 26 | options.unshift(default_branch) | ... | ... |