diff --git a/app/views/layouts/base_courses.html.erb b/app/views/layouts/base_courses.html.erb
index d7e7bba90..305eaaa29 100644
--- a/app/views/layouts/base_courses.html.erb
+++ b/app/views/layouts/base_courses.html.erb
@@ -86,11 +86,15 @@
<% end %>
- <%if @course.tea_id == User.current.id && (@course.outline == 0 || BlogComment.where(:id=>@course.outline).count == 0) %>
+ <%if User.current && @course.tea_id == User.current.id && (@course.outline == 0 || BlogComment.where(:id=>@course.outline).count == 0) %>
- <% elsif @course.tea_id == User.current.id && @course.outline != 0 && BlogComment.where(:id=>@course.outline).count != 0%>
+ <% elsif User.current && @course.tea_id == User.current.id && @course.outline != 0 && BlogComment.where(:id=>@course.outline).count != 0%>
- <% elsif @course.tea_id != User.current.id %>
+ <% elsif User.current && @course.tea_id != User.current.id && !@course.is_public? && User.current.member_of_course?(@course)%>
+
+ <% elsif User.current && @course.tea_id != User.current.id && @course.is_public?%>
+
+ <%else%>
<%end %>
@@ -233,6 +237,7 @@
}
}else{
+ $("#course_outline_list").html('');
$("#course_outline_hint").show();
}
}