Skip to content

Commit 9c1fa51

Browse files
committed
fix linting
1 parent 609e651 commit 9c1fa51

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

contentcuration/contentcuration/frontend/channelEdit/components/sidePanels/SubmitToCommunityLibrarySidePanel/index.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,6 @@
438438
specialPermissions,
439439
includedLicenses,
440440
checkAndTriggerAudit: checkAndTriggerLicenseAudit,
441-
currentVersionData,
442441
} = useLicenseAudit(props.channel, currentChannelVersion);
443442
444443
const allSpecialPermissionsChecked = ref(true);
@@ -478,10 +477,7 @@
478477
479478
if (!isPublishing.value) {
480479
await fetchPublishedData();
481-
console.log('versionDetail:', versionDetail.value);
482480
await checkAndTriggerLicenseAudit();
483-
console.log('specialPermissions:', specialPermissions.value);
484-
console.log('currentVersionData:', currentVersionData.value);
485481
}
486482
});
487483
@@ -496,7 +492,7 @@
496492
if (!languageCodes) return undefined;
497493
if (languageCodes.length === 0) return null;
498494
499-
return languageCodes.map(code => LanguagesMap.get(code).readable_name).join(', ');
495+
return languageCodes.map(code => LanguagesMap.get(code)?.readable_name || code).join(', ');
500496
});
501497
502498
function categoryIdToName(categoryId) {

contentcuration/contentcuration/tests/test_channel_version.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
from contentcuration.models import ChannelVersion
22
from contentcuration.models import SecretToken
33
from contentcuration.tests import testdata
4+
from django.core.exceptions import ValidationError
45
from contentcuration.tests.base import StudioTestCase
56

67

@@ -51,9 +52,8 @@ def test_unique_constraint(self):
5152
channel=self.channel,
5253
version=1,
5354
)
54-
from django.db.utils import IntegrityError
5555

56-
with self.assertRaises(IntegrityError):
56+
with self.assertRaises(ValidationError):
5757
ChannelVersion.objects.create(
5858
channel=self.channel,
5959
version=1,

0 commit comments

Comments
 (0)