From bb5ef1959630875bdb8663a55f14c19d0abedce8 Mon Sep 17 00:00:00 2001 From: Max Melentiev Date: Mon, 10 Dec 2018 22:22:02 +0530 Subject: [PATCH] Add missing require statements --- lib/paperclip/attachment.rb | 2 ++ lib/paperclip/callback_compatability.rb | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/paperclip/attachment.rb b/lib/paperclip/attachment.rb index 9c93ea2..5efb267 100644 --- a/lib/paperclip/attachment.rb +++ b/lib/paperclip/attachment.rb @@ -1,6 +1,8 @@ require 'fastimage' require 'paperclip/styles_parser' +require 'active_support/core_ext/module/delegation' +require 'active_support/core_ext/string/inflections' module Paperclip # The Attachment class manages the files for a given attachment. It saves diff --git a/lib/paperclip/callback_compatability.rb b/lib/paperclip/callback_compatability.rb index 1e437d7..dd550c7 100644 --- a/lib/paperclip/callback_compatability.rb +++ b/lib/paperclip/callback_compatability.rb @@ -1,3 +1,5 @@ +require 'active_support/version' + module Paperclip module CallbackCompatability module_function @@ -33,7 +35,7 @@ module Paperclip module Rails3 module Defining TERMINATOR = - if Gem::Version.new(ActiveRecord::VERSION::STRING) >= Gem::Version.new('4.1') + if Gem::Version.new(ActiveSupport::VERSION::STRING) >= Gem::Version.new('4.1') ->(target, result) { result == false } else 'result == false'