From 773635e355fc5cb59f2d6fa6b74b10b155eaabe5 Mon Sep 17 00:00:00 2001 From: Stephan Date: Tue, 1 Sep 2020 12:21:36 +0100 Subject: [PATCH] ComposerRepository: avoid notice if includes do not provide a sha1 --- src/Composer/Repository/ComposerRepository.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Composer/Repository/ComposerRepository.php b/src/Composer/Repository/ComposerRepository.php index 649c2f115..57a95449f 100644 --- a/src/Composer/Repository/ComposerRepository.php +++ b/src/Composer/Repository/ComposerRepository.php @@ -637,7 +637,7 @@ class ComposerRepository extends ArrayRepository implements ConfigurableReposito if (isset($data['includes'])) { foreach ($data['includes'] as $include => $metadata) { - if ($this->cache->sha1($include) === $metadata['sha1']) { + if (isset($metadata['sha1']) && $this->cache->sha1($include) === $metadata['sha1']) { $includedData = json_decode($this->cache->read($include), true); } else { $includedData = $this->fetchFile($include);