for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
Install GitHub App
<?php
namespace Backpack\CRUD\app\Library\CrudPanel\Hooks;
final class BackpackHooks
{
public array $hooks = [];
public static function register(string $hook, string|array $operations, callable $callback): void
$operations = is_array($operations) ? $operations : [$operations];
is_array($operations)
true
foreach ($operations as $operation) {
self::$hooks[$operation][$hook] = $callback;
}
public static function run(string $hook, string $operation, array $parameters): void
if (isset(self::$operationHooks[$operation][$hook])) {
operationHooks
Backpack\CRUD\app\Librar...nel\Hooks\BackpackHooks
self::$hooks[$operation][$hook](...$parameters);
public static function has(string $hook, string $operation): bool
return isset(self::$hooks[$operation][$hook]);