@@ -8,15 +8,15 @@ def self.active_record?(model)
88
99 def self . included ( model )
1010 if Devise ::Orm . active_record? ( model )
11- model . include DirtyTrackingActiveRecordMethods
12- model . extend ActiveRecordQueryMethods
11+ model . include ActiveRecordDirtyTracking
12+ model . extend ActiveRecordFinders
1313 else
14- model . include DirtyTrackingMongoidMethods
15- model . extend MongoidQueryMethods
14+ model . include MongoidDirtyTracking
15+ model . extend MongoidFinders
1616 end
1717 end
1818
19- module ActiveRecordQueryMethods
19+ module ActiveRecordFinders
2020 def devise_find_by_id ( id )
2121 id = id . first if id . is_a? ( Array )
2222 find_by ( id : id )
@@ -32,7 +32,7 @@ def devise_find_first(conditions)
3232 end
3333 end
3434
35- module MongoidQueryMethods
35+ module MongoidFinders
3636 def devise_find_by_id ( id )
3737 id = id . first if id . is_a? ( Array )
3838 where ( id : id ) . first
@@ -48,7 +48,7 @@ def devise_find_first(conditions)
4848 end
4949 end
5050
51- module DirtyTrackingActiveRecordMethods
51+ module ActiveRecordDirtyTracking
5252 def devise_email_before_last_save
5353 email_before_last_save
5454 end
@@ -74,7 +74,7 @@ def devise_respond_to_and_will_save_change_to_attribute?(attribute)
7474 end
7575 end
7676
77- module DirtyTrackingMongoidMethods
77+ module MongoidDirtyTracking
7878 def devise_email_before_last_save
7979 respond_to? ( :email_previously_was ) ? email_previously_was : email_was
8080 end
0 commit comments