Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
tabacitu authored and StyleCIBot committed Jul 16, 2024
1 parent 49c11b5 commit b45f7f6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/BassetManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -237,12 +237,12 @@ public function bassetBlock(string $asset, string $code, bool $output = true, bo

// when cache is set to false we will just mark the asset as loaded to avoid
// loading the same asset twice and return the raw code to the browser.
if($cache === false) {
if($this->isloaded($asset)) {
if ($cache === false) {
if ($this->isloaded($asset)) {
return $this->loader->finish(StatusEnum::LOADED);
}
$this->markAsLoaded($asset);

echo $code;

return $this->loader->finish(StatusEnum::LOADED);
Expand Down
2 changes: 1 addition & 1 deletion src/BassetServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ protected function registerBladeDirectives()
$blockName = $parameters[0];
// keep cache as true by default when not provided in block definition
$cacheOption = $parameters[1] ?? true;

return "<?php \$bassetBlock = {$blockName}; \$cache = {$cacheOption}; ob_start(); ?>";
});

Expand Down

0 comments on commit b45f7f6

Please sign in to comment.