From 6d0f777ec80e8b02e99db67774ffad1eb9ca87db Mon Sep 17 00:00:00 2001 From: qasimgulzar Date: Fri, 22 Nov 2024 12:48:44 +0500 Subject: [PATCH] fix: quality issues --- openedx/core/djangoapps/common_initialization/apps.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/openedx/core/djangoapps/common_initialization/apps.py b/openedx/core/djangoapps/common_initialization/apps.py index f6977c68897e..36dc8375309b 100644 --- a/openedx/core/djangoapps/common_initialization/apps.py +++ b/openedx/core/djangoapps/common_initialization/apps.py @@ -37,7 +37,9 @@ def _add_required_adapters(): if 'postgresql' in connection.vendor.lower(): from opaque_keys.edx.locator import CourseLocator from psycopg2.extensions import QuotedString, register_adapter + def adapt_course_locator(course_locator): + return QuotedString(course_locator._to_string()) # lint-amnesty, pylint: disable=protected-access # Register the adapter