Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8808021
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T02:30:53+00:00 2026-06-14T02:30:53+00:00

I have devise for authentication and i have not used validatable and i send

  • 0

I have devise for authentication and i have not used validatable and i send the request and along to it i send a type. for example

http://localhost:3000/signup/new?type=twitter 

in the above shown i have used type=twitterand in case it is twitter i do not want to validate email i.e., do not need validates_presence_of :email but in case i send type=email then i want to check presence of mail and whether mail has not already taken and check mail specified is valid or not? How can i do this? Please help me.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T02:30:55+00:00Added an answer on June 14, 2026 at 2:30 am

    You could add the following to your controller:

    if params[:type] == 'twitter'
      user.save(:validate => false)
    

    However, I wouldn’t advise doing this as you would then have invalid data in your database. It would be best if you actually asked the user to enter his email when logging in with Twitter. This whole challenge is tackled by Ryan Bates on this episode about omniauth.

    EDIT: I investigated a bit and if you check devise’s source code, you’ll notice that they now have this method called email_required?.

    So all you have to do is override that method. How does you user model look? How are you allowing the user to login using Twitter? If you edit your question and show us that, we might be able to help you a little further.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have used Devise + OmniAuth as authentication mechanism to authenticate user with facebook,
I have been using devise for authentication and cancan for authorization in my application.
I have an webapplication that uses devise database authentication for all the controllers, however
I have two devise models: User and Member As such, I'm specifying authentication keys
I have a Rails 3.1.3 app which uses devise for users authentication and soft-deletes
So I am using Devise for user authentication in my rails app. I have
I currently have a simple app that includes user authentication through devise and a
I have a Rails 3.1 application that uses devise for authentication. I am trying
I currently have an app that uses regular Devise authentication for logging in and
Is it possible to have Devise not worry about passwords at all? I am

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.