From b87fed4ab7e9baf5385a4ba7782e2fe3decc57b5 Mon Sep 17 00:00:00 2001 From: Sergio Mendolia Date: Fri, 13 Oct 2023 23:56:40 +0200 Subject: [PATCH] better message --- src/Command/BooksTagCommand.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Command/BooksTagCommand.php b/src/Command/BooksTagCommand.php index dc0d1ce9..fc844e61 100644 --- a/src/Command/BooksTagCommand.php +++ b/src/Command/BooksTagCommand.php @@ -63,17 +63,19 @@ protected function execute(InputInterface $input, OutputInterface $output): int continue; } + $io->writeln('looking for suggestions for '.$book->getTitle()); + $suggestions = $this->bookSuggestions->getCategorySuggestions($book); if (count($suggestions['tags']) === 0) { $suggestions = $this->bookSuggestions->getGoogleSuggestions($book); } if(count($suggestions['tags']) > 0){ - $io->writeln('- tags found for '.$book->getTitle()); + $io->writeln('- tags found'); $book->setTags(array_values($suggestions['tags'])); } $summary = count($suggestions['summary']) > 0 ? current($suggestions['summary']) : ''; if ($summary !== '' && ($book->getSummary() === null || $book->getSummary() === '')) { - $io->writeln('- summary found for '.$book->getTitle()); + $io->writeln('- summary found'); $book->setSummary($summary); } $this->entityManager->flush();