Sha256: ebf8a53d92aa5cdba55e122e0e79c593098cd362ba9faf575c4fe1738a78832a
Contents?: true
Size: 775 Bytes
Versions: 6
Compression:
Stored size: 775 Bytes
Contents
# Devise Guests [![Build Status](https://travis-ci.org/cbeer/devise-guests.png?branch=master)](https://travis-ci.org/cbeer/devise-guests) A drop-in guest user implementation for devise (I'm using "user" to mean my devise model, but you should be able to use any model you want, just like devise) ## Installation ```ruby # install devise first # gem install devise # rails g devise:install # rails g devise User gem install devise-guests rails g devise_guests User ``` ## Usage ```ruby # Where you might use current_user; now you can use current_or_guest_user # which returns current_user # (for logged in users) => User<id: 1, email: ...> # or guest_user # ( for anonymous users) => User<id: nil, email: guest_RANDOMENOUGHSTRING_@example.com, guest: true> ```
Version data entries
6 entries across 6 versions & 1 rubygems
Version | Path |
---|---|
devise-guests-0.7.0 | README.md |
devise-guests-0.6.1 | README.md |
devise-guests-0.6.0 | README.md |
devise-guests-0.5.0 | README.md |
devise-guests-0.3.3 | README.md |
devise-guests-0.3.2 | README.md |