You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was playing around with a fresh build of obtvse and found that clicking on the "NEW DRAFT" button, optionally starting to type a title, and then clicking Delete -> OK caused the error "undefined method `destroy' for nil:NilClass". I got around the issue editing app/controllers/posts_controller.rb so@post.destroy is wrapped in an if-end block:
if @post.present?
@post.destroy
end
I hope that helps.
The text was updated successfully, but these errors were encountered:
I was playing around with a fresh build of obtvse and found that clicking on the "NEW DRAFT" button, optionally starting to type a title, and then clicking Delete -> OK caused the error "undefined method `destroy' for nil:NilClass". I got around the issue editing app/controllers/posts_controller.rb so@post.destroy is wrapped in an if-end block:
if @post.present?
@post.destroy
end
I hope that helps.
The text was updated successfully, but these errors were encountered: