diff options
author | Alexis Reigel <mail@koffeinfrei.org> | 2017-08-24 14:21:26 +0200 |
---|---|---|
committer | Alexis Reigel <mail@koffeinfrei.org> | 2017-09-05 12:18:31 +0200 |
commit | 508ff17b3405a4e2275fa137bd7322b728db8ed4 (patch) | |
tree | 7e00cb57f432d92b4a6af349678efe54bb2546cb /app/workers | |
parent | ff413ec28d5f0721646cea223fb5e5a054bde31e (diff) | |
download | gitlab-ce-508ff17b3405a4e2275fa137bd7322b728db8ed4.tar.gz |
pass whole commit to Gitlab::Gpg::Commit again
we need the commit object for the updated verification that also checks
the committer's email to match the gpg key and user's emails.
Diffstat (limited to 'app/workers')
-rw-r--r-- | app/workers/create_gpg_signature_worker.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/workers/create_gpg_signature_worker.rb b/app/workers/create_gpg_signature_worker.rb index f34dff2d656..9b5ff17aafa 100644 --- a/app/workers/create_gpg_signature_worker.rb +++ b/app/workers/create_gpg_signature_worker.rb @@ -6,7 +6,11 @@ class CreateGpgSignatureWorker project = Project.find_by(id: project_id) return unless project + commit = project.commit(commit_sha) + + return unless commit + # This calculates and caches the signature in the database - Gitlab::Gpg::Commit.new(project, commit_sha).signature + Gitlab::Gpg::Commit.new(commit).signature end end |