-
Notifications
You must be signed in to change notification settings - Fork 251
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
Refinery::Blog.user_class #290
Conversation
…finery::Blog engine to work out-of-box with existing Rails applications. This issue was tracked in refinery#286.
@parndt Hey, just checking in - any way I can help to get this merged? |
@@ -10,4 +10,7 @@ Refinery::Blog.configure do |config| | |||
# config.share_this_key = <%= Refinery::Blog.share_this_key.inspect %> | |||
|
|||
# config.page_url = <%= Refinery::Blog.page_url.inspect %> | |||
|
|||
# If you're grafting onto an existing app, change this to your User class | |||
# Refinery::Blog.user_class = User |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should read:
# Refinery::Blog.user_class = <%= Refinery::Blog.user_class.inspect %>
I think that the user_class should be implemented like forem due to rubysherpas/forem#88 |
Thanks for the reminder! |
@radar hey are you able to give valuable input on this PR based on your experience with Spree and Forem? |
@parndt Sorry for the delay - just got back from vacation. I'll implement your feedback and check in by this weekend. |
Hey, sorry for the extreme lateness on this. I just pushed a commit to make everything work like forem i.e. you pass in a string instead of a class literal. Please take a look and let me know if you have any more feedback. Thanks! |
Sorry forgot to copy you @parndt |
Don't worry I'm already subscribed to the issue.. I was just sleeping 💤 I really think this should go against the master branch as it's a new feature.. |
OK, I've merged the feature into master branch (new pull request). |
This issue was tracked in #286. I've added a config setting so that existing Rails applications can specify their own user class (generally User, but could be anything).
Only added in 2-0-stable as that's what I use in prod, but happy to take a crack at merging the patch into master as well (still learning the ins and outs of Git, so might take me a little bit to get the hang of it).