All threads / DateTime comparison in Rails 6
Ask A Question

Notifications

You’re not receiving notifications from this thread.

DateTime comparison in Rails 6

Ethan Lee-Tyson asked in Rails

Hi -

I built this simple app to practice with ActionMailer as I learn Rails (LINK: https://github.com/eleetyson/time-capsule).

It works fine locally but when I deployed to Heroku, it seems that the datetime comparison in the messages controller's create action is not working properly.

Here is the messages controllers (LINK: https://github.com/eleetyson/time-capsule/blob/master/app/controllers/messages_controller.rb) -- I keep hitting that 2nd flash notice ("invalid delivery time...") even when I input a datetime in the future.

Any suggestions for how to debug?

Other relevant links:

Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 66,029+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Screencast tutorials to help you learn Ruby on Rails, Javascript, Hotwire, Turbo, Stimulus.js, PostgreSQL, MySQL, Ubuntu, and more. Icons by Icons8

    © 2022 GoRails, LLC. All rights reserved.