Skip to content

Commit

Permalink
refactor: use "origin" in badge template models favour of "type" for …
Browse files Browse the repository at this point in the history
…consistency
  • Loading branch information
wowkalucky committed Mar 26, 2024
1 parent f54aa17 commit af05ee3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions credentials/apps/badges/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class BadgeTemplate(AbstractCredential):
Describes badge credential type.
"""

TYPE = "openedx"
ORIGIN = "openedx"

uuid = models.UUIDField(
unique=True, default=uuid.uuid4, help_text=_("Unique badge template ID.")
Expand All @@ -37,7 +37,7 @@ def save(self, *args, **kwargs):
super().save()
# auto-evaluate type:
if not self.origin:
self.origin = self.TYPE
self.origin = self.ORIGIN
self.save(*args, **kwargs)


Expand Down

0 comments on commit af05ee3

Please sign in to comment.