Skip to content

Commit

Permalink
DBP: Config merging added.
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitry-ivanov committed Aug 2, 2017
1 parent 67ec841 commit 4857497
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/DbProfilerServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ class DbProfilerServiceProvider extends ServiceProvider
{
private static $counter;

/* @laravel-versions */
public function register()
{
$this->mergeConfig();
}

private static function tickCounter()
Expand Down Expand Up @@ -69,4 +69,14 @@ private function applyBindings($sql, array $bindings)

return $sql;
}

private function mergeConfig()
{
$this->mergeConfigFrom($this->getConfigPath(), 'db-profiler');
}

private function getConfigPath()
{
return __DIR__ . '/../config/db-profiler.php';
}
}

0 comments on commit 4857497

Please sign in to comment.