Conditions | 3 |
Paths | 5 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
34 | public function handle(): ?OuvrageTemplate |
||
35 | { |
||
36 | try { |
||
37 | $this->logger->info('GOOGLE...'); |
||
38 | |||
39 | return OuvrageFactory::GoogleFromIsbn($this->isbn); |
||
40 | } catch (Throwable $e) { |
||
41 | $this->logger->warning("*** ERREUR GOOGLE Isbn Search ***" . $e->getMessage()); |
||
42 | if (strpos($e->getMessage(), 'Could not resolve host: www.googleapis.com') === false) { |
||
43 | throw $e; |
||
44 | } |
||
45 | } |
||
46 | |||
47 | return null; |
||
48 | } |
||
49 | } |