Skip to content

Commit

Permalink
Removing deprecated alias_method_chain
Browse files Browse the repository at this point in the history
Issue #19
  • Loading branch information
brenes committed Jun 7, 2016
1 parent 77d9b18 commit f865a92
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions app/models/no_cms/blocks/concerns/model_with_slots.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ module ModelWithSlots
# In the dup implementation we configure the `dup_block_when_duping_slot`
# virtual attribute of the slot with the same value than the attribute
# from this model. This way we propagate the configuration.
def dup_with_slots options = {}
duplicated = dup_without_slots
def dup
duplicated = super
# We just need to dub root slots, if there are nested slots
# will be dupped in each slot
block_slots.roots.each do |slot|
Expand All @@ -36,8 +36,6 @@ def dup_with_slots options = {}
end
duplicated
end
alias_method_chain :dup, :slots

end

end
Expand Down

0 comments on commit f865a92

Please sign in to comment.