We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b2f2f65 commit 355b26bCopy full SHA for 355b26b
‎src/UrlShortenerManager.php
@@ -17,6 +17,9 @@
17
use LaraCrafts\UrlShortener\Http\ShorteStShortener;
18
use LaraCrafts\UrlShortener\Http\TinyUrlShortener;
19
20
+/**
21
+ * @method string shorten(\Psr\Http\Message\UriInterface|string $url, array $options = [])
22
+ */
23
class UrlShortenerManager implements FactoryContract
24
{
25
protected $app;
@@ -36,6 +39,18 @@ public function __construct(Application $app)
36
39
$this->shorteners = [];
37
40
}
38
41
42
+ /**
43
+ * Dynamically call the default driver instance.
44
+ *
45
+ * @param string $method
46
+ * @param array $parameters
47
+ * @return mixed
48
49
+ public function __call($method, $parameters)
50
+ {
51
+ return $this->driver()->$method(...$parameters);
52
+ }
53
+
54
/**
55
* Call a custom driver creator.
56
*
0 commit comments