Skip to content

Instantly share code, notes, and snippets.

@mrpunkin
Created March 24, 2015 23:23
Show Gist options
  • Select an option

  • Save mrpunkin/385528dbd73a50db5908 to your computer and use it in GitHub Desktop.

Select an option

Save mrpunkin/385528dbd73a50db5908 to your computer and use it in GitHub Desktop.
decorators/shopify_api/order_decorator.rb
module ShopifyAPI
module OrderDecorator
included do
before_update :remove_source_name
end
private
def remove_source_name
attributes.delete(:source_name)
end
end
end
ShopifyAPI::Order.send(:include, ShopifyAPI::OrderDecorator)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment