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

Fix Time fields bug which occurs when Time value is nil #1226

Merged
merged 2 commits into from
Oct 5, 2020

Conversation

rnitta
Copy link
Contributor

@rnitta rnitta commented Oct 15, 2018

When there are null-allowed Time column on DB,

<%= field.data.strftime("%I:%M%p").to_s %>

This code can raise error, becauseundefined method 'strftime' for nil:NilClass if field.data is nil

so I add code to check if time value is nill and some specs

please check it.

and,
CircleCi tests failed due to dependencies vulnerability.
please check this, too. #1225

@GeoffAbtion
Copy link

Is it possible to rerun the CI on this PR, the dependencies should be up to date now.

@nickcharlton nickcharlton added bug breakages in functionality that is implemented fields new fields, displaying and editing data labels Jan 2, 2020
@nickcharlton nickcharlton force-pushed the fix/time-fields-null-safety branch from f62b4d2 to f7c6b93 Compare October 5, 2020 18:39
@nickcharlton
Copy link
Member

Thanks for your work here! I rebased and now I'll merge it.

@nickcharlton nickcharlton merged commit e841b45 into thoughtbot:master Oct 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug breakages in functionality that is implemented fields new fields, displaying and editing data
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants