Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the remember_me_token cookie name configurable #179

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

robinvdvleuten
Copy link
Contributor

This PR makes the default remember_me_token cookie name configurable to whatever seems to fit for the application.


expect(User).to receive(:authenticate).with('[email protected]', 'secret', '1') { |&block| block.call(user, nil) }
expect(user).to receive(:remember_me!)
expect(user).to receive(:remember_me_token).and_return('abracadabra').twice
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this receive the token twice? I'm not very familiar with the callback system, but this looks like it might be a side-effect of the double callback bug in 0.13.0

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@athix to be honest, I copied it over from the testcase above this one. So it could be part of the double callback bug. When I remove the twice method though, it gives an error. Could it be that the double callback bug is still relevant?

@robinvdvleuten
Copy link
Contributor Author

@athix I've implemented your remarks. Could you take a look again?

@kentarohorie
Copy link
Contributor

@robinvdvleuten It seems that CI failed.

@joshbuker joshbuker added the to be implemented in v1 This issue or pull request will be resolved in the v1 rework, but has not yet been completed. label May 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
to be implemented in v1 This issue or pull request will be resolved in the v1 rework, but has not yet been completed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants