New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Comments not displaying on Lesson page for unsupported themes #2284

Merged
merged 1 commit into from Oct 25, 2018

Conversation

Projects
None yet
2 participants
@alexsanford
Contributor

alexsanford commented Oct 24, 2018

On unsupported themes, Lesson comments were not being displayed at all. This was because of a change that was made in the comment handling and a failure to clean up the outdated version of the code.

Testing

  • Go to Sensei > Settings > Lesson and check the box "This will allow learners to post comments on the single Lesson page, only learner who have access to the Lesson will be allowed to comment."

  • Ensure you are using an unsupported theme.

  • Visit a Lesson page on the frontend. The comments should be displayed.

  • Disable the setting. The comments should be hidden on the Lesson page.

  • Check the other CPT pages. For Course and Quiz, the comments UI should not be displayed. For Messages, the comments UI should be displayed.

Remove unnecessary comment handling
This was actually causing a regression on the Lesson page. Lesson
comments were not being displayed at all.

After this fix, comments will always be hidden outside of Sensei's
template render, and only rendered by Sensei when needed.

@alexsanford alexsanford added this to the 1.12.1 milestone Oct 24, 2018

@alexsanford alexsanford self-assigned this Oct 24, 2018

@alexsanford alexsanford requested review from donnapep and ice9js Oct 24, 2018

@donnapep

👍

@alexsanford alexsanford merged commit e16be8d into master Oct 25, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@alexsanford alexsanford deleted the fix/theme-compat-lesson-comments-display branch Oct 25, 2018

@donnapep donnapep modified the milestones: 1.12.2, 1.12.1 Oct 27, 2018

@donnapep donnapep changed the title from Bugfix: Comments not displaying on Lesson page to Comments not displaying on Lesson page Oct 27, 2018

@donnapep donnapep restored the fix/theme-compat-lesson-comments-display branch Oct 29, 2018

@donnapep donnapep deleted the fix/theme-compat-lesson-comments-display branch Oct 29, 2018

@donnapep donnapep changed the title from Comments not displaying on Lesson page to Comments not displaying on Lesson page for unsupported themes Nov 1, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment