Sha256: f4d20fc9c4fb855f738f4bfc04748629999a2be4945c26099ec4a17dbe77345e
Contents?: true
Size: 360 Bytes
Versions: 1
Compression:
Stored size: 360 Bytes
Contents
# frozen_string_literal: true module CurrentSession module SessionMethods # # Implementation of using UIDs as session tokens # module UidSession def find(&block) user_class.find_by(uid: session_token).try(&block) end def create(user) yield user.uid end def destroy end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
current_session-0.1.6 | lib/current_session/session_methods/uid_session.rb |