mirror of
https://github.com/ditkrg/validates_timeliness.git
synced 2026-01-25 07:16:41 +00:00
reload to clear cached value. Fixes mongoid.
This commit is contained in:
@@ -32,4 +32,10 @@ module Mongoid::Document
|
||||
include ValidatesTimeliness::HelperMethods
|
||||
include ValidatesTimeliness::AttributeMethods
|
||||
include ValidatesTimeliness::ORM::Mongoid
|
||||
|
||||
def reload_with_timeliness
|
||||
@attributes_cache = {}
|
||||
reload_without_timeliness
|
||||
end
|
||||
alias_method_chain :reload, :timeliness
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user