Skip to content
This repository has been archived by the owner on Apr 11, 2024. It is now read-only.

Commit

Permalink
Differentiated the names of the VersionMethods modules so that each c…
Browse files Browse the repository at this point in the history
…alls included only once (Rails 4.1-compatibility)
  • Loading branch information
boblail committed Jun 6, 2014
1 parent beccc57 commit a3bec7c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lib/vestal_versions/users.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ module Users

included do
attr_accessor :updated_by
Version.class_eval{ include VersionMethods }
Version.class_eval{ include UserVersionMethods }
end

# Methods added to versioned ActiveRecord::Base instances to enable versioning with additional
Expand All @@ -22,7 +22,7 @@ def version_attributes
end

# Instance methods added to VestalVersions::Version to accomodate incoming user information.
module VersionMethods
module UserVersionMethods
extend ActiveSupport::Concern

included do
Expand Down
4 changes: 2 additions & 2 deletions lib/vestal_versions/version_tagging.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def tag_version(tag)
end

# Instance methods included into VestalVersions::Version to enable version tagging.
module VersionMethods
module TaggingVersionMethods
extend ActiveSupport::Concern

included do
Expand All @@ -46,6 +46,6 @@ def validate_tags?
tagged? && tag != 'deleted'
end

Version.class_eval{ include VersionMethods }
Version.class_eval{ include TaggingVersionMethods }
end
end

0 comments on commit a3bec7c

Please sign in to comment.