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

Use correct Arel for null #409

Merged
merged 2 commits into from
Aug 21, 2020
Merged

Use correct Arel for null #409

merged 2 commits into from
Aug 21, 2020

Conversation

thom-oman
Copy link
Contributor

In #408 we saw that due to the changes in #399 we weren't handling null values correctly when creating new transitions. Arel cannot cast nil to null and we see

> Arel::Nodes::SqlLiteral.new(nil)
TypeError: no implicit conversion of nil into String
from (pry):1:in `initialize'

casting to null returns 'NULL' for mysql, which rails does not like, and
defaults to true, which causes a transition conflict.
@thom-oman thom-oman merged commit aa8f309 into master Aug 21, 2020
@thom-oman thom-oman deleted the thom/allow_nullable branch August 21, 2020 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants