diff options
| author | Lin Jen-Shin <godfat@godfat.org> | 2017-11-30 15:20:00 +0800 |
|---|---|---|
| committer | Lin Jen-Shin <godfat@godfat.org> | 2017-11-30 15:20:00 +0800 |
| commit | 85be6d83be4632c76760e373da131a90afb093b9 (patch) | |
| tree | 7ed7312dd8ad6e8e0ebd30b78774261c30c55d4e /app/models/commit.rb | |
| parent | 689658456f706be7278fbf50fcde9c7f43cd0655 (diff) | |
| parent | f7254a4060b30e3134c6cf932eaba0fc8e249e9a (diff) | |
| download | gitlab-ce-85be6d83be4632c76760e373da131a90afb093b9.tar.gz | |
Merge remote-tracking branch 'upstream/master' into no-ivar-in-modules
* upstream/master: (170 commits)
support ordering of project notes in notes api
Redirect to an already forked project if it exists
Reschedule the migration to populate fork networks
Create fork networks for forks for which the source was deleted.
Fix item name and namespace text overflow in Projects dropdown
Minor backport from EE
fix link that was linking to `html` instead of `md`
Backport epic tasklist
Add timeouts for Gitaly calls
SSHUploadPack over Gitaly is now OptOut
fix icon colors in commit list
Fix star icon color/stroke
Backport border inline edit
Add checkboxes to automatically run AutoDevops pipeline
BE for automatic pipeline when enabling Auto DevOps
I am certainly weary of debugging sidekiq but I don't think that's what was meant
Ensure MRs always use branch refs for comparison
Fix issue comment submit button disabled on GFM paste
Lock seed-fu at the correct version in Gemfile.lock
Improve indexes on merge_request_diffs
...
Diffstat (limited to 'app/models/commit.rb')
| -rw-r--r-- | app/models/commit.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/app/models/commit.rb b/app/models/commit.rb index 8401d99a08f..6b28d290f99 100644 --- a/app/models/commit.rb +++ b/app/models/commit.rb @@ -109,12 +109,12 @@ class Commit @link_reference_pattern ||= super("commit", /(?<commit>#{COMMIT_SHA_PATTERN})/) end - def to_reference(from_project = nil, full: false) - commit_reference(from_project, id, full: full) + def to_reference(from = nil, full: false) + commit_reference(from, id, full: full) end - def reference_link_text(from_project = nil, full: false) - commit_reference(from_project, short_id, full: full) + def reference_link_text(from = nil, full: false) + commit_reference(from, short_id, full: full) end def diff_line_count @@ -381,8 +381,8 @@ class Commit private - def commit_reference(from_project, referable_commit_id, full: false) - reference = project.to_reference(from_project, full: full) + def commit_reference(from, referable_commit_id, full: false) + reference = project.to_reference(from, full: full) if reference.present? "#{reference}#{self.class.reference_prefix}#{referable_commit_id}" |
