Skip to content

Commit 994f09b

Browse files
committed
fixed test and removed code scanning's warning
1 parent 8a89d9f commit 994f09b

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

appointment/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -833,7 +833,7 @@ def get_instance(cls):
833833

834834
def __str__(self):
835835
return f"Config {self.pk}: slot_duration={self.slot_duration}, lead_time={self.lead_time}, " \
836-
f"finish_time={self.finish_time}, etc."
836+
f"finish_time={self.finish_time}"
837837

838838

839839
class PaymentInfo(models.Model):

appointment/utils/db_helpers.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -388,15 +388,12 @@ def create_recurring_appointment(appointment_request, recurrence_rule, end_date=
388388
"""Create a recurring appointment from an existing AppointmentRequest."""
389389
from appointment.models import RecurringAppointment
390390

391-
recurring_appointment = RecurringAppointment.objects.create(
391+
return RecurringAppointment.objects.create(
392392
appointment_request=appointment_request,
393393
recurrence_rule=_parse_recurrence_rule(recurrence_rule),
394394
end_date=end_date
395395
)
396396

397-
logger.info(f"Created recurring appointment: {recurring_appointment}")
398-
return recurring_appointment
399-
400397

401398
def _parse_recurrence_rule(recurrence_rule_string):
402399
"""Convert RRULE string to django-recurrence Recurrence object."""

0 commit comments

Comments
 (0)