Class: VAProfileRedis::V2::Cache

Inherits:
Object
  • Object
show all
Includes:
SentryLogging
Defined in:
app/models/va_profile_redis/v2/cache.rb

Class Method Summary collapse

Methods included from SentryLogging

#log_exception_to_sentry, #log_message_to_sentry, #non_nil_hash?, #normalize_level, #rails_logger, #set_sentry_metadata

Class Method Details

.invalidate(user) ⇒ Object

Invalidates the cache set in VAProfileRedis::V2::ContactInformation through our Common::RedisStore#destroy method.

Parameters:

  • user (User)

    The current user



15
16
17
18
19
# File 'app/models/va_profile_redis/v2/cache.rb', line 15

def self.invalidate(user)
  contact_info = VAProfileRedis::V2::ContactInformation.find(user.uuid)

  contact_info.destroy if contact_info.present?
end