edx/edx-platform — pull request #3754 by theJohnnyBrown (2014-05-16 03:31:59+00:00)
Title: show a friendly message for an empty course rather than an error page

See also the [trello discussion](https://trello.com/c/fVzRPOd1/2-forum-autoprovisioning-fails-for-new-user) and [possibly related commit](https://github.com/edx/edx-platform/pull/2957).

Changes LMS so that when a course has no content, i.e. no units have been added by the instructor in studio, we show a message indicating that the course has no content. This is a change from the previous behavior showing various 404/500 responses depending on whether sections/subsections were present.

To verify the fix, I did the following steps:

+ Created a new account in studio
+ activated account in same browser session
+ Created a course
+ Clicked "view live"
+ Clicked "Discussions"
+ Added a section in studio
+ Clicked "view live" -> "discussions"
+ Added a subsection in studio
+ Clicked "view live" -> "discussions"
+ Added a unit to the subsection, set the unit to public, did not add a component to the unit
+ Clicked "view live" -> "discussions"
+ Added a component to the unit
+ Clicked "view live" -> "discussions"
+ Logged out, logged back in, returned to course
+ Clicked "view live" -> "discussions"

@antoviaque