obtvse
obtvse copied to clipboard
[refresh] undefined method 'model_name' when no posts exist and accessing admin section
I installed a fresh clone of the refresh branch and so I had no posts. When I accessed the admin section I got a "undefined method" error. Turns out the posts_controller#new method sets "@post" equal to a post that it looks up or to "Post.first". However, if you have no posts the view fails to render.
We need some testing definitely, would be much appreciated if you could investigate!