Exception Notification and Edge

Changeset 8669 breaks the exception_notification plugin ... raising Unprocessed view path found in .

Drop the following in config/initializers/exception_notification.rb ...

ExceptionNotifier.exception_recipients = %w(you@yourdomain.com)
ExceptionNotifier.class_eval do 
  remove_method :template_root 
  ExceptionNotifier.template_root = "#{RAILS_ROOT}/vendor/plugins/exception_notification/lib/../views" 
end
Posted on February 4th | 0 comments | Filed Under: RailsRuby | read on

Edge callback refactorings && attachment_fu

Edge changeset 8664 introduces ActiveSupport::Callbacks.

This currently breaks attachment_fu's callback internals and may affect other plugins as well ...

module Technoweenie
  module AttachmentFu

    module InstanceMethods

      def self.included( base )
        base.define_callbacks *[:after_resize, :after_attachment_saved, :before_thumbnail_saved]
      end  

      def callback_with_args(method, arg = self)
         notify(method)

          result = run_callbacks(method, { :object => arg }) { |result, object| result == false }

          if result != false && respond_to_without_attributes?(method)
            result = send(method)
          end

          return result
      end      

      def run_callbacks(kind, options = {}, &block)
        options.reverse_merge!( :object => self )
        ::ActiveSupport::Callbacks::Callback.run(self.class.send("#{kind}_callback_chain"), options[:object], options, &block)
      end      
    end
  end
end

Hope the above monkey patch relieves a bout of intense swearing.

Posted on January 19th | 1 comment | Filed Under: RailsRuby | read on

View archives for February 2008.


About me

Cape Town
  • Currently living in Portugal
  • CV available on request
  • I do Travel Industry solutions and booking systems
  • I like i18n and L10n
  • I despise all things political
  • You may reach me @ +351 969622126,
  • Skype me with lourens.naude
  • or mail me at lourens@methodmissing.com