From cc5ded555a8de574b0c6b7c77f34a11e9095b55a Mon Sep 17 00:00:00 2001 From: Yanislav Igonin Date: Sat, 4 Sep 2021 21:46:56 +0300 Subject: [PATCH] minimize seeds count --- repositories/seeds.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/repositories/seeds.go b/repositories/seeds.go index 87d610a..7e201ce 100644 --- a/repositories/seeds.go +++ b/repositories/seeds.go @@ -75,7 +75,7 @@ func seedLocal() { func seedDb() { // preparing seed data with parent posts with files var parentPosts []Post - for i := 1; i < 100; i++ { + for i := 1; i < 10; i++ { post := getPost(i, nil) parentPosts = append(parentPosts, post) } @@ -97,7 +97,7 @@ func seedDb() { } // making child posts - for i := 0; i < 100; i++ { + for i := 0; i < 10; i++ { // getting child post with files childPost := getPost(0, &parentPostID) childPostID, err := Posts.Create(childPost)