Class: OmniHooks::Strategies::Developer

Inherits:
Object
  • Object
show all
Includes:
OmniHooks::Strategy
Defined in:
lib/omnihooks/strategies/developer.rb

Overview

The Developer strategy is a very simple strategy that can be used as a placeholder in your application until a different authentication strategy is swapped in. It has zero security and should never be used in a production setting.

## Usage

To use the Developer strategy, all you need to do is put it in like any other strategy:

This will create a strategy that, when the user visits ‘/auth/developer` they will be presented a form that prompts for (by default) their name and email address. The auth hash will be populated with these fields and the `uid` will simply be set to the provided email.

Examples:

Basic Usage


use OmniAuth::Builder do
  provider :developer
end

Custom Fields


use OmniAuth::Builder do
  provider :developer,
    :fields => [:first_name, :last_name],
    :uid_field => :last_name
end

Instance Attribute Summary

Attributes included from OmniHooks::Strategy

#options

Method Summary

Methods included from OmniHooks::Strategy

#call, #call!, included, #initialize, #inspect, #request