Skip to content

Commit

Permalink
Compiler.log & Deprecations.log
Browse files Browse the repository at this point in the history
  • Loading branch information
ProklUng committed Jan 27, 2022
1 parent 63f3002 commit 48cd8ce
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -734,9 +734,14 @@ private function initialize(string $fileName): ?ContainerBuilder
$buildDir.'/'.$class.'Deprecations.log',
serialize(array_values($collectedLogs))
);

@file_put_contents(
$buildDir.'/'.$class.'Compiler.log',
null !== static::$containerBuilder ? implode("\n", static::$containerBuilder->getCompiler()->getLog()) : ''
null !== static::$containerBuilder
?
implode("\n", array_unique(static::$containerBuilder->getCompiler()->getLog()))
:
''
);
}
}
Expand Down

0 comments on commit 48cd8ce

Please sign in to comment.