diff --git a/lms/djangoapps/commerce/management/commands/configure_commerce.py b/lms/djangoapps/commerce/management/commands/configure_commerce.py index fda5dce431..f849d85aeb 100644 --- a/lms/djangoapps/commerce/management/commands/configure_commerce.py +++ b/lms/djangoapps/commerce/management/commands/configure_commerce.py @@ -53,9 +53,11 @@ class Command(BaseCommand): checkout_on_ecommerce = options.get('checkout_on_ecommerce') # We are keeping id=1, because as of now, there are only one commerce configuration for the system. + pk_id = 1 CommerceConfiguration.objects.update_or_create( - id=1, + id=pk_id, defaults={ + 'id': pk_id, 'enabled': not disable, 'checkout_on_ecommerce_service': checkout_on_ecommerce, }