Sha256: 37aae5a3d61995edc33c6b7799f22447ae394d74410784f836c2770f515bf6ab
Contents?: true
Size: 523 Bytes
Versions: 3
Compression:
Stored size: 523 Bytes
Contents
module SshkeyAware extend ActiveSupport::Concern included do around_filter SshkeySessionSweeper end def sshkey_uploaded? @has_key = false if session[:has_sshkey] logger.debug " Hit has_sshkey cache #{session.inspect}" @has_keys = session[:has_sshkey] else key = Key.first :as => current_user @has_keys = key ? true : false session[:has_sshkey] = @has_keys end @has_key end end RestApi::Base.observers << SshkeySessionSweeper SshkeySessionSweeper.instance
Version data entries
3 entries across 3 versions & 1 rubygems