summaryrefslogtreecommitdiff
path: root/yaksh/models.py
diff options
context:
space:
mode:
Diffstat (limited to 'yaksh/models.py')
-rw-r--r--yaksh/models.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/yaksh/models.py b/yaksh/models.py
index e9b2c1b..3182cc8 100644
--- a/yaksh/models.py
+++ b/yaksh/models.py
@@ -3215,7 +3215,7 @@ class QRcode(models.Model):
num = 5
for i in range(40):
try:
- self.short_key = key[0 : num]
+ self.short_key = key[0:num]
break
except django.db.IntegrityError:
num = num + 1
@@ -3234,7 +3234,6 @@ class QRcodeHandler(models.Model):
answerpaper = models.ForeignKey(AnswerPaper, on_delete=models.CASCADE)
question = models.ForeignKey(Question, on_delete=models.CASCADE)
-
def __str__(self):
return 'QRcode Handler for {0}'.format(self.user.username)
@@ -3253,4 +3252,3 @@ class QRcodeHandler(models.Model):
def can_use(self):
return self.answerpaper.is_attempt_inprogress()
-