From 3b58fed1ab202fd03da38f8a42eec829f4590329 Mon Sep 17 00:00:00 2001 From: Kevin Perez Date: Tue, 23 Jan 2024 10:24:26 -0600 Subject: [PATCH] Fix rubocop offenses --- lib/wicked_pdf.rb | 4 +--- test/unit/wicked_pdf_test.rb | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/wicked_pdf.rb b/lib/wicked_pdf.rb index ab34d959..9c08a348 100644 --- a/lib/wicked_pdf.rb +++ b/lib/wicked_pdf.rb @@ -25,9 +25,7 @@ class WickedPdf include Progress def self.config=(config) - unless @@silence_deprecations - ::Kernel.warn "WickedPdf.config= is deprecated and will be removed in future versions. Use WickedPdf.configure instead." - end + ::Kernel.warn 'WickedPdf.config= is deprecated and will be removed in future versions. Use WickedPdf.configure instead.' unless @@silence_deprecations @@config = config end diff --git a/test/unit/wicked_pdf_test.rb b/test/unit/wicked_pdf_test.rb index 40dfdef9..d5a49899 100644 --- a/test/unit/wicked_pdf_test.rb +++ b/test/unit/wicked_pdf_test.rb @@ -12,7 +12,7 @@ def setup c.test = 'foobar' end - assert WickedPdf.config == { :exe_path => ENV['WKHTMLTOPDF_BIN'] || '/usr/local/bin/wkhtmltopdf', test: 'foobar' } + assert WickedPdf.config == { :exe_path => ENV['WKHTMLTOPDF_BIN'] || '/usr/local/bin/wkhtmltopdf', :test => 'foobar' } end test 'should clear config through .clear_config class method' do