Skip to content

Commit 88bd000

Browse files
committed
Remove Shoop dependency
1 parent 0eca757 commit 88bd000

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

composer.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@
1111
],
1212
"require": {
1313
"php": "^7.2",
14-
"league/commonmark": "~1.5",
15-
"8fold/php-shoop": "~0.5"
14+
"league/commonmark": "~1.5"
1615
},
1716
"require-dev": {
1817
"phpunit/phpunit": "~9.1"

src/AbbreviationInlineParser.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ public function parse(InlineParserContext $inlineContext): bool
3333
$cursor->restoreState($previousCursor);
3434
return false;
3535
}
36-
37-
list($abbr, $title) = Shoop::string($abbr)->dropFirst(2)->dropLast()
38-
->divide("](", false, 2);
36+
$abbr = substr($abbr, 2);
37+
$abbr = substr($abbr, 0, -1);
38+
list($abbr, $title) = explode("](", $abbr, 2);
3939
$elem = new Abbreviation($abbr, $title);
4040

4141
$inlineContext->getContainer()->appendChild($elem);

0 commit comments

Comments
 (0)