From de79b7aed30fe22a87c6ecefc9eaab8f1304d9d2 Mon Sep 17 00:00:00 2001
From: Matthieu Fesselier <matthieu.fesselier@gmail.com>
Date: Mon, 14 Jan 2019 15:35:20 +0700
Subject: [PATCH] syntax: improve factories

---
 .../management/commands/mock_notification.py                  | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/djangoldp_notification/management/commands/mock_notification.py b/djangoldp_notification/management/commands/mock_notification.py
index d534a2e..507a3f6 100644
--- a/djangoldp_notification/management/commands/mock_notification.py
+++ b/djangoldp_notification/management/commands/mock_notification.py
@@ -8,7 +8,5 @@ class Command(BaseCommand):
         parser.add_argument('--size', type=int, default=0, help='Number of notifications to create')
 
     def handle(self, *args, **options):
-        for i in range(0, options['size']):
-            notif = NotificationFactory.create()
-
+        NotificationFactory.create_batch(options['size'])
         self.stdout.write(self.style.SUCCESS('Successful data mock install'))
-- 
GitLab