1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2026-02-05 18:54:03 +00:00

Fix code style (php-cs-fixer)

This commit is contained in:
PHP CS Fixer 2025-01-04 14:21:01 +00:00
parent e2e20ad6db
commit 143b494e51

View file

@ -43,8 +43,12 @@ class DisallowSqliteAttach implements Feature
static::$loadExtensionSupported = method_exists($pdo, 'loadExtension'); static::$loadExtensionSupported = method_exists($pdo, 'loadExtension');
} }
if (static::$loadExtensionSupported === false) return false; if (static::$loadExtensionSupported === false) {
if (static::$extensionPath === false) return false; return false;
}
if (static::$extensionPath === false) {
return false;
}
$suffix = match (PHP_OS_FAMILY) { $suffix = match (PHP_OS_FAMILY) {
'Linux' => 'so', 'Linux' => 'so',
@ -57,7 +61,9 @@ class DisallowSqliteAttach implements Feature
$arm = $arch === 'aarch64' || $arch === 'arm64'; $arm = $arch === 'aarch64' || $arch === 'arm64';
static::$extensionPath ??= realpath(base_path('vendor/stancl/tenancy/extensions/lib/' . ($arm ? 'arm/' : '') . 'noattach.' . $suffix)); static::$extensionPath ??= realpath(base_path('vendor/stancl/tenancy/extensions/lib/' . ($arm ? 'arm/' : '') . 'noattach.' . $suffix));
if (static::$extensionPath === false) return false; if (static::$extensionPath === false) {
return false;
}
$pdo->loadExtension(static::$extensionPath); // @phpstan-ignore method.notFound $pdo->loadExtension(static::$extensionPath); // @phpstan-ignore method.notFound