Skip to content

Commit

Permalink
Feedback and contact forms will auto-fill a user's email if they are …
Browse files Browse the repository at this point in the history
…logged in (#1282)
  • Loading branch information
fivefootbot authored Dec 19, 2024
1 parent cfc15a4 commit 1e8838d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/controllers/contacts_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ class ContactsController < ApplicationController

def new
@contact = Contact.new
@contact.email = current_user.email if current_user.present?
end

def create
Expand Down
1 change: 1 addition & 0 deletions app/controllers/feedback_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ class FeedbackController < ApplicationController

def new
@feedback = Feedback.new
@feedback.email = current_user.email if current_user.present?
end

def create
Expand Down

0 comments on commit 1e8838d

Please sign in to comment.