diff --git a/src/UrlGenerators/LocalUrlGenerator.php b/src/UrlGenerators/LocalUrlGenerator.php index 4db35b0..53d1d8f 100644 --- a/src/UrlGenerators/LocalUrlGenerator.php +++ b/src/UrlGenerators/LocalUrlGenerator.php @@ -47,9 +47,9 @@ public function getPublicPath() if (! $this->isPubliclyAccessible()) { throw MediaUrlException::mediaNotPubliclyAccessible($this->getAbsolutePath(), public_path()); } - if($this->isInWebroot()){ + if ($this->isInWebroot()) { $path = str_replace(public_path(), '', $this->getAbsolutePath()); - }else{ + } else { $path = rtrim($this->getDiskConfig('prefix', 'storage'), '/') . '/' . $this->media->getDiskPath(); } diff --git a/tests/integration/UrlGenerators/LocalUrlGeneratorTest.php b/tests/integration/UrlGenerators/LocalUrlGeneratorTest.php index eedee29..98f0a9b 100644 --- a/tests/integration/UrlGenerators/LocalUrlGeneratorTest.php +++ b/tests/integration/UrlGenerators/LocalUrlGeneratorTest.php @@ -31,7 +31,6 @@ public function test_it_accepts_public_visiblity() { $generator = $this->setupGenerator('public_storage'); $this->assertEquals('http://localhost/prefix/foo/bar.jpg', $generator->getUrl()); - } protected function setupGenerator($disk = 'uploads')