Skip to content

Commit

Permalink
Cleanup obsolete code
Browse files Browse the repository at this point in the history
  • Loading branch information
kylekatarnls committed Jan 17, 2020
1 parent 2dccdf5 commit b90a790
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 13 deletions.
4 changes: 1 addition & 3 deletions src/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -219,11 +219,9 @@ public function registerPugBladeCompiler()
*/
public function getConfig()
{
$key = $this->version() >= 5 ? 'laravel-pug' : 'laravel-pug::config';

return array_merge([
'allow_composite_extensions' => true,
], $this->app->make('config')->get($key));
], $this->app->make('config')->get('laravel-pug'));
}

/**
Expand Down
1 change: 1 addition & 0 deletions tests/BladeDirectivesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ protected function setUp(): void
}

/**
* @covers ::version
* @covers ::getCompilerCreator
* @covers ::getPugEngine
* @covers ::getEngineResolver
Expand Down
10 changes: 0 additions & 10 deletions tests/ServiceProviderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,6 @@
use Pug\Pug;

include_once __DIR__ . '/helpers.php';

$file = __DIR__ . '/LaravelTestApp.php';
$contents = file_get_contents($file);

$contents = version_compare(PHP_VERSION, '5.6.0-dev', '>=')
? str_replace('(/*...$environments*/)', '(...$environments)', $contents)
: str_replace('(...$environments)', '(/*...$environments*/)', $contents);

file_put_contents($file, $contents);

include_once __DIR__ . '/LaravelTestApp.php';
include_once __DIR__ . '/Laravel5ServiceProvider.php';

Expand Down

0 comments on commit b90a790

Please sign in to comment.