diff --git a/app/presenters/upload_presenter.rb b/app/presenters/upload_presenter.rb index dc7a62ce2..d510ac869 100644 --- a/app/presenters/upload_presenter.rb +++ b/app/presenters/upload_presenter.rb @@ -6,7 +6,8 @@ class UploadPresenter < Presenter def status(template) case @upload.status when /duplicate: (\d+)/ - template.link_to(@upload.status.gsub(/error: RuntimeError - /, ""), template.__send__(:post_path, $1)) + dup_post_id = $1 + template.link_to(@upload.status.gsub(/error: RuntimeError - /, ""), template.__send__(:post_path, dup_post_id)) else @upload.status