chore: removed enable_moderation_reason_codes flag from discussion app (#33822)
* chore: removed enable_moderation_reason_codes flag from discussion app
This commit is contained in:
@@ -101,7 +101,6 @@ from ..django_comment_client.utils import (
|
||||
has_discussion_privileges,
|
||||
is_commentable_divided
|
||||
)
|
||||
from ..toggles import ENABLE_DISCUSSION_MODERATION_REASON_CODES
|
||||
from .exceptions import CommentNotFoundError, DiscussionBlackOutException, DiscussionDisabledError, ThreadNotFoundError
|
||||
from .forms import CommentActionsForm, ThreadActionsForm, UserOrdering
|
||||
from .pagination import DiscussionAPIPagination
|
||||
@@ -365,7 +364,6 @@ def get_course(request, course_key):
|
||||
"enable_in_context": course_config.enable_in_context,
|
||||
"group_at_subsection": course_config.plugin_configuration.get("group_at_subsection", False),
|
||||
'learners_tab_enabled': ENABLE_LEARNERS_TAB_IN_DISCUSSIONS_MFE.is_enabled(course_key),
|
||||
"reason_codes_enabled": ENABLE_DISCUSSION_MODERATION_REASON_CODES.is_enabled(course_key),
|
||||
"edit_reasons": [
|
||||
{"code": reason_code, "label": label}
|
||||
for (reason_code, label) in EDIT_REASON_CODES.items()
|
||||
|
||||
@@ -212,7 +212,6 @@ class GetCourseTest(ForumsEnableMixin, UrlResetMixin, SharedModuleStoreTestCase)
|
||||
'is_user_admin': False,
|
||||
'user_roles': {'Student'},
|
||||
'learners_tab_enabled': False,
|
||||
'reason_codes_enabled': False,
|
||||
'edit_reasons': [{'code': 'test-edit-reason', 'label': 'Test Edit Reason'}],
|
||||
'post_close_reasons': [{'code': 'test-close-reason', 'label': 'Test Close Reason'}],
|
||||
}
|
||||
|
||||
@@ -536,7 +536,6 @@ class CourseViewTest(DiscussionAPIViewTestMixin, ModuleStoreTestCase):
|
||||
'is_user_admin': False,
|
||||
"user_roles": ["Student"],
|
||||
'learners_tab_enabled': False,
|
||||
"reason_codes_enabled": False,
|
||||
"edit_reasons": [{"code": "test-edit-reason", "label": "Test Edit Reason"}],
|
||||
"post_close_reasons": [{"code": "test-close-reason", "label": "Test Close Reason"}],
|
||||
}
|
||||
|
||||
@@ -24,17 +24,6 @@ ENABLE_LEARNERS_TAB_IN_DISCUSSIONS_MFE = CourseWaffleFlag(
|
||||
f'{WAFFLE_FLAG_NAMESPACE}.enable_learners_tab_in_discussions_mfe', __name__
|
||||
)
|
||||
|
||||
# .. toggle_name: discussions.enable_moderation_reason_codes
|
||||
# .. toggle_implementation: CourseWaffleFlag
|
||||
# .. toggle_default: False
|
||||
# .. toggle_description: Waffle flag to toggle support for the new edit and post close reason codes
|
||||
# .. toggle_use_cases: temporary, open_edx
|
||||
# .. toggle_creation_date: 2022-02-22
|
||||
# .. toggle_target_removal_date: 2022-09-22
|
||||
ENABLE_DISCUSSION_MODERATION_REASON_CODES = CourseWaffleFlag(
|
||||
f'{WAFFLE_FLAG_NAMESPACE}.enable_moderation_reason_codes', __name__
|
||||
)
|
||||
|
||||
# .. toggle_name: discussions.enable_reported_content_email_notifications
|
||||
# .. toggle_implementation: CourseWaffleFlag
|
||||
# .. toggle_default: False
|
||||
|
||||
Reference in New Issue
Block a user