mirror of
https://github.com/mailcow/mailcow-dockerized.git
synced 2026-10-29 12:43:25 +00:00
[Web] Update composer libraries
This commit is contained in:
1297 files changed
+71585
-24460
No files matched your search
@@ -6,6 +6,8 @@ use BadMethodCallException;
|
||||
use Closure;
|
||||
use ReflectionClass;
|
||||
use ReflectionMethod;
|
||||
use RuntimeException;
|
||||
use Throwable;
|
||||
|
||||
trait Macroable
|
||||
{
|
||||
@@ -21,6 +23,9 @@ trait Macroable
|
||||
*
|
||||
* @param string $name
|
||||
* @param object|callable $macro
|
||||
*
|
||||
* @param-closure-this static $macro
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public static function macro($name, $macro)
|
||||
@@ -117,7 +122,11 @@ trait Macroable
|
||||
$macro = static::$macros[$method];
|
||||
|
||||
if ($macro instanceof Closure) {
|
||||
$macro = $macro->bindTo($this, static::class);
|
||||
try {
|
||||
$macro = $macro->bindTo($this, static::class) ?? throw new RuntimeException;
|
||||
} catch (Throwable) {
|
||||
$macro = $macro->bindTo(null, static::class);
|
||||
}
|
||||
}
|
||||
|
||||
return $macro(...$parameters);
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"php": "^8.1"
|
||||
"php": "^8.2"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
@@ -23,7 +23,7 @@
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "12.x-dev"
|
||||
}
|
||||
},
|
||||
"config": {
|
||||
|
||||
Reference in new issue
Block a user