mr_video
mr_video copied to clipboard
Deleting the last episode of a cassette results in error on cassettes index view
When I delete all episodes of a cassette and then go back to the cassettes index view, it tries to display time_ago_in_words(cassette.updated_at)
but raises an NoMethodError in MrVideo::Cassettes#index
since updated_at
is nil
at this point.
Would be rather easy to prevent (based on episodes.any?
or similar) but I was thinking if we might want to delete the whole cassette when it's empty.
@quidproquo Thoughts? :)