Skip to content

Commit

Permalink
Fix duplicate decleration warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
tbrisker committed Jan 9, 2018
1 parent 03d6a9e commit 366e0e2
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ Fixed
[#390](https://github.com/collectiveidea/audited/pull/390)
- Passing an invalid version to `revision` returns `nil` instead of last version
[#384](https://github.com/collectiveidea/audited/pull/384)
- Fix duplicate deceleration warnings
[#398](https://github.com/collectiveidea/audited/pull/398)


## 4.5.0 (2017-05-22)
Expand Down
5 changes: 3 additions & 2 deletions lib/audited.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@

module Audited
class << self
attr_accessor :ignored_attributes, :current_user_method, :audit_class
attr_accessor :ignored_attributes, :current_user_method
attr_writer :audit_class

def audit_class
@audit_class || Audit
@audit_class ||= Audit
end

def store
Expand Down
1 change: 0 additions & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
require 'audited'
require 'audited_spec_helpers'
require 'support/active_record/models'
load "audited/sweeper.rb" # force to reload sweeper

SPEC_ROOT = Pathname.new(File.expand_path('../', __FILE__))

Expand Down

0 comments on commit 366e0e2

Please sign in to comment.