Skip to content

Conversation

@matthew342
Copy link
Contributor

Setting a model attribute that contains a VoltTime to nil raises 'undefined method `getutc' for nil:NilClass' when volt/models/model.rb:213 tries to compare the new (nil) value to the old value.

Example stacktrace:

NoMethodError:
       undefined method `getutc' for nil:NilClass
     # /Users/Matt/.rvm/gems/ruby-2.3.0@volt/bundler/gems/volt-f942b92385ad/lib/volt/helpers/time/volt_time.rb:97:in `=='
     # /Users/Matt/.rvm/gems/ruby-2.3.0@volt/bundler/gems/volt-f942b92385ad/lib/volt/models/model.rb:213:in `!='
     # /Users/Matt/.rvm/gems/ruby-2.3.0@volt/bundler/gems/volt-f942b92385ad/lib/volt/models/model.rb:213:in `set'
     # /Users/Matt/.rvm/gems/ruby-2.3.0@volt/bundler/gems/volt-f942b92385ad/lib/volt/models/field_helpers.rb:90:in `block in field'

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