11package com .kvark900 .api .configuration .setupDataLoaders ;
22
3- import com .kvark900 .api .configuration .security .user .*;
43import com .kvark900 .api .model .Author ;
54import com .kvark900 .api .model .Book ;
65import com .kvark900 .api .model .Topic ;
1312import org .springframework .transaction .annotation .Transactional ;
1413
1514import java .math .BigDecimal ;
16- import java .util .*;
15+ import java .util .HashSet ;
16+ import java .util .Set ;
1717
1818/**
1919 * Created by Keno&Kemo on 03.03.2018..
@@ -154,7 +154,7 @@ public void onApplicationEvent(final ContextRefreshedEvent event) {
154154 }
155155
156156 @ Transactional
157- private Author createAuthorIfNotFound (String name , String surname ) {
157+ Author createAuthorIfNotFound (String name , String surname ) {
158158 Author author = authorService .findByNameAndSurname (name , surname );
159159 if (author == null ) {
160160 author = new Author (name , surname );
@@ -164,7 +164,7 @@ private Author createAuthorIfNotFound(String name, String surname) {
164164 }
165165
166166 @ Transactional
167- private Topic createTopicIfNotFound (String name , String description ) {
167+ Topic createTopicIfNotFound (String name , String description ) {
168168 Topic topic = topicService .findByName (name );
169169 if (topic == null ) {
170170 topic = new Topic (name , description );
@@ -174,9 +174,9 @@ private Topic createTopicIfNotFound(String name, String description) {
174174 }
175175
176176 @ Transactional
177- private void createBookIfNotFound (String title , Set <Author > authors ,
178- String yearOfPublication , String description ,
179- Set <Topic > topics , BigDecimal price ) {
177+ void createBookIfNotFound (String title , Set <Author > authors ,
178+ String yearOfPublication , String description ,
179+ Set <Topic > topics , BigDecimal price ) {
180180 Book book = bookService .findByTitle (title );
181181 if (book == null ) {
182182 book = new Book ();
0 commit comments