Skip to content

Commit

Permalink
fix minor typos and grammer
Browse files Browse the repository at this point in the history
  • Loading branch information
beingmattlevy committed May 5, 2024
1 parent 7387187 commit 2789bc6
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/controllers/home_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def index

redirect_to event_ticket_request_path(event_id: most_recent_event.to_param, id: ticket_request.id)

else0
else
redirect_to new_event_ticket_request_path(event_id: most_recent_event.to_param)
end
else
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/ticket_requests_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def new
if signed_in?
@user = current_user

existing_request = TicketRequest.where(user_id: current_user.id, event_id: @event).order(:created_at).first
existing_request = TicketRequest.where(user_id: @user.id, event_id: @event).order(:created_at).first
if existing_request
redirect_to event_ticket_request_path(event_id: @event.id, id: existing_request.id)
end
Expand Down
4 changes: 2 additions & 2 deletions app/models/event.rb
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ def ticket_sales_open?
elsif ticket_sales_end_time && Time.current.after?(ticket_sales_end_time)
errors.add(:ticket_sales_end_time, 'Tickets are no longer on sale for this event.')
elsif Time.current.after?(end_time)
errors.add(:end_time, 'This event has ended, so no ticket sales sare accepted anymore.')
errors.add(:end_time, 'This event has ended and ticket sales are closed.')
else
return true
end
Expand All @@ -151,7 +151,7 @@ def ticket_requests_open?
if ticket_requests_end_time && Time.current.after?(ticket_requests_end_time)
errors.add(:ticket_requests_end_time, 'Ticket requests are no longer accepted.')
elsif Time.current.after?(end_time)
errors.add(:end_time, 'This event has ended, so no ticket requests are accepted anymore.')
errors.add(:end_time, 'This event has ended and ticket sales are closed.')
else
return true
end
Expand Down

0 comments on commit 2789bc6

Please sign in to comment.