Skip to content

Commit 55c0da7

Browse files
committed
removed deprecated stuff
1 parent 0cfda47 commit 55c0da7

File tree

3 files changed

+0
-131
lines changed

3 files changed

+0
-131
lines changed

src/Utils/Callback.php

Lines changed: 0 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -20,47 +20,6 @@ final class Callback
2020
{
2121
use Nette\StaticClass;
2222

23-
/**
24-
* @param string|object|callable $callable class, object, callable
25-
* @deprecated use Closure::fromCallable()
26-
*/
27-
public static function closure($callable, string $method = null): \Closure
28-
{
29-
trigger_error(__METHOD__ . '() is deprecated, use Closure::fromCallable().', E_USER_DEPRECATED);
30-
try {
31-
return \Closure::fromCallable($method === null ? $callable : [$callable, $method]);
32-
} catch (\TypeError $e) {
33-
throw new Nette\InvalidArgumentException($e->getMessage());
34-
}
35-
}
36-
37-
38-
/**
39-
* Invokes callback.
40-
* @return mixed
41-
* @deprecated
42-
*/
43-
public static function invoke($callable, ...$args)
44-
{
45-
trigger_error(__METHOD__ . '() is deprecated, use native invoking.', E_USER_DEPRECATED);
46-
self::check($callable);
47-
return $callable(...$args);
48-
}
49-
50-
51-
/**
52-
* Invokes callback with an array of parameters.
53-
* @return mixed
54-
* @deprecated
55-
*/
56-
public static function invokeArgs($callable, array $args = [])
57-
{
58-
trigger_error(__METHOD__ . '() is deprecated, use native invoking.', E_USER_DEPRECATED);
59-
self::check($callable);
60-
return $callable(...$args);
61-
}
62-
63-
6423
/**
6524
* Invokes internal PHP function with own error handler.
6625
* @return mixed

src/Utils/ObjectMixin.php

Lines changed: 0 additions & 41 deletions
This file was deleted.

tests/Utils/Callback.invoke.phpt

Lines changed: 0 additions & 49 deletions
This file was deleted.

0 commit comments

Comments
 (0)