delete_files

This commit is contained in:
Olu Amey
2022-11-20 07:52:04 -05:00
parent a2a42348c8
commit aaf5e6f432
601 changed files with 4 additions and 107964 deletions
@@ -1,36 +0,0 @@
<?php
/**
* This file is part of CodeIgniter 4 framework.
*
* (c) CodeIgniter Foundation <admin@codeigniter.com>
*
* For the full copyright and license information, please view
* the LICENSE file that was distributed with this source code.
*/
namespace CodeIgniter\View;
use CodeIgniter\View\Exceptions\ViewException;
trait ViewDecoratorTrait
{
/**
* Runs the generated output through any declared
* view decorators.
*/
protected function decorateOutput(string $html): string
{
$decorators = \config('View')->decorators;
foreach ($decorators as $decorator) {
if (! is_subclass_of($decorator, ViewDecoratorInterface::class)) {
throw ViewException::forInvalidDecorator($decorator);
}
$html = $decorator::decorate($html);
}
return $html;
}
}