File tree Expand file tree Collapse file tree 11 files changed +22
-22
lines changed
Expand file tree Collapse file tree 11 files changed +22
-22
lines changed Original file line number Diff line number Diff line change 66use Embed \Detectors \Code as Detector ;
77use Embed \EmbedCode ;
88use function Embed \html ;
9- use function Embed \match ;
9+ use function Embed \matchPath ;
1010
1111class Code extends Detector
1212{
@@ -15,7 +15,7 @@ public function detect(): ?EmbedCode
1515 $ uri = $ this ->extractor ->getUri ();
1616 $ path = $ uri ->getPath ();
1717
18- if (!match ('/details/* ' , $ path )) {
18+ if (!matchPath ('/details/* ' , $ path )) {
1919 return null ;
2020 }
2121
Original file line number Diff line number Diff line change 77use Embed \Detectors \Code as Detector ;
88use Embed \EmbedCode ;
99use function Embed \html ;
10- use function Embed \match ;
10+ use function Embed \matchPath ;
1111
1212class Code extends Detector
1313{
@@ -21,7 +21,7 @@ private function fallback(): ?EmbedCode
2121 {
2222 $ uri = $ this ->extractor ->getUri ();
2323
24- if (!match ('/audio/* ' , $ uri ->getPath ())) {
24+ if (!matchPath ('/audio/* ' , $ uri ->getPath ())) {
2525 return null ;
2626 }
2727
Original file line number Diff line number Diff line change 77use Embed \Detectors \Code as Detector ;
88use Embed \EmbedCode ;
99use function Embed \html ;
10- use function Embed \match ;
10+ use function Embed \matchPath ;
1111
1212class Code extends Detector
1313{
@@ -21,7 +21,7 @@ private function fallback(): ?EmbedCode
2121 {
2222 $ uri = $ this ->extractor ->getUri ();
2323
24- if (!match ('/photos/* ' , $ uri ->getPath ())) {
24+ if (!matchPath ('/photos/* ' , $ uri ->getPath ())) {
2525 return null ;
2626 }
2727
Original file line number Diff line number Diff line change 66use Embed \Detectors \Code as Detector ;
77use Embed \EmbedCode ;
88use function Embed \html ;
9- use function Embed \match ;
9+ use function Embed \matchPath ;
1010
1111class Code extends Detector
1212{
@@ -21,7 +21,7 @@ private function fallback(): ?EmbedCode
2121 $ uri = $ this ->extractor ->getUri ();
2222 $ path = $ uri ->getPath ();
2323
24- if (!match ('/*/*/blob/* ' , $ path )) {
24+ if (!matchPath ('/*/*/blob/* ' , $ path )) {
2525 return null ;
2626 }
2727
Original file line number Diff line number Diff line change 55
66use function Embed \getDirectory ;
77use Embed \HttpApiTrait ;
8- use function Embed \match ;
8+ use function Embed \matchPath ;
99
1010class Api
1111{
@@ -15,10 +15,10 @@ protected function fetchData(): array
1515 {
1616 $ uri = $ this ->extractor ->getUri ();
1717
18- if (!match ('/i/* ' , $ uri ->getPath ())) {
18+ if (!matchPath ('/i/* ' , $ uri ->getPath ())) {
1919 $ uri = $ this ->extractor ->getRequest ()->getUri ();
2020
21- if (!match ('/i/* ' , $ uri ->getPath ())) {
21+ if (!matchPath ('/i/* ' , $ uri ->getPath ())) {
2222 return [];
2323 }
2424 }
Original file line number Diff line number Diff line change 66use Embed \Detectors \Code as Detector ;
77use Embed \EmbedCode ;
88use function Embed \html ;
9- use function Embed \match ;
9+ use function Embed \matchPath ;
1010
1111class Code extends Detector
1212{
@@ -20,7 +20,7 @@ private function fallback(): ?EmbedCode
2020 {
2121 $ uri = $ this ->extractor ->getUri ();
2222
23- if (!match ('/pin/* ' , $ uri ->getPath ())) {
23+ if (!matchPath ('/pin/* ' , $ uri ->getPath ())) {
2424 return null ;
2525 }
2626
Original file line number Diff line number Diff line change 66use Embed \Detectors \Code as Detector ;
77use Embed \EmbedCode ;
88use function Embed \html ;
9- use function Embed \match ;
9+ use function Embed \matchPath ;
1010
1111class Code extends Detector
1212{
@@ -20,7 +20,7 @@ private function fallback(): ?EmbedCode
2020 {
2121 $ uri = $ this ->extractor ->getUri ();
2222
23- if (!match ('/gist/* ' , $ uri ->getPath ())) {
23+ if (!matchPath ('/gist/* ' , $ uri ->getPath ())) {
2424 return null ;
2525 }
2626
Original file line number Diff line number Diff line change 66use Embed \Detectors \Code as Detector ;
77use Embed \EmbedCode ;
88use function Embed \html ;
9- use function Embed \match ;
9+ use function Embed \matchPath ;
1010
1111class Code extends Detector
1212{
@@ -20,7 +20,7 @@ private function fallback(): ?EmbedCode
2020 {
2121 $ uri = $ this ->extractor ->getUri ();
2222
23- if (!match ('/view/* ' , $ uri ->getPath ())) {
23+ if (!matchPath ('/view/* ' , $ uri ->getPath ())) {
2424 return null ;
2525 }
2626
Original file line number Diff line number Diff line change 55
66use function Embed \getDirectory ;
77use Embed \HttpApiTrait ;
8- use function Embed \match ;
8+ use function Embed \matchPath ;
99
1010class Api
1111{
@@ -15,7 +15,7 @@ protected function fetchData(): array
1515 {
1616 $ uri = $ this ->extractor ->getUri ();
1717
18- if (!match ('/wiki/* ' , $ uri ->getPath ())) {
18+ if (!matchPath ('/wiki/* ' , $ uri ->getPath ())) {
1919 return [];
2020 }
2121
Original file line number Diff line number Diff line change 55
66use Embed \Detectors \Feeds as Detector ;
77use function Embed \getDirectory ;
8- use function Embed \match ;
8+ use function Embed \matchPath ;
99use Psr \Http \Message \UriInterface ;
1010
1111class Feeds extends Detector
@@ -23,7 +23,7 @@ private function fallback(): array
2323 {
2424 $ uri = $ this ->extractor ->getUri ();
2525
26- if (!match ('/channel/* ' , $ uri ->getPath ())) {
26+ if (!matchPath ('/channel/* ' , $ uri ->getPath ())) {
2727 return [];
2828 }
2929
You can’t perform that action at this time.
0 commit comments