Skip to content

Commit

Permalink
Rails 4.1 compatibility
Browse files Browse the repository at this point in the history
[#1677](https://trello.com/c/FOYXAamH)

Details
-------
* MERGED laserlemon#107
  • Loading branch information
Mathieu Robardey committed Aug 13, 2014
1 parent 281e04f commit f455241
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions lib/vestal_versions/users.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ module Users

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

# Methods added to versioned ActiveRecord::Base instances to enable versioning with additional
# user information.


private
# Overrides the +version_attributes+ method to include user information passed into the
# parent object, by way of a +updated_by+ attr_accessor.
Expand All @@ -22,7 +22,7 @@ def version_attributes
end

# Instance methods added to VestalVersions::Version to accomodate incoming user information.
module VersionMethods
module UsersMethods
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 TaggingMethods
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 TaggingMethods }
end
end

0 comments on commit f455241

Please sign in to comment.