Passed
Push — issue-71 ( 957702...1ee81d )
by Sebastian
03:42
created
vendorPath.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -13,13 +13,13 @@
 block discarded – undo
13 13
      */
14 14
     function vendorPath() {
15 15
 
16
-        if (file_exists(__DIR__ . '/vendor/')) {
17
-            return __DIR__ . '/vendor';
16
+        if (file_exists(__DIR__.'/vendor/')) {
17
+            return __DIR__.'/vendor';
18 18
         } else {
19
-            if (!file_exists(__DIR__ . '/../../')) {
19
+            if (!file_exists(__DIR__.'/../../')) {
20 20
                 return false;
21 21
             } else {
22
-                return __DIR__ . '/../..';
22
+                return __DIR__.'/../..';
23 23
             }
24 24
         }
25 25
     }
Please login to merge, or discard this patch.
example/index.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-include __DIR__ . "/../vendor/autoload.php";
3
+include __DIR__."/../vendor/autoload.php";
4 4
 use Seboettg\CiteProc\StyleSheet;
5 5
 use Seboettg\CiteProc\CiteProc;
6 6
 
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
             margin: 0.5em 0;
32 32
         }
33 33
 
34
-        <?php echo "\n" . $cssStyles; ?>
34
+        <?php echo "\n".$cssStyles; ?>
35 35
     </style>
36 36
 </head>
37 37
 <body>
@@ -87,20 +87,20 @@  discard block
 block discarded – undo
87 87
     "bibliography" => [
88 88
         "author" => function($authorItem, $renderedText) {
89 89
             if (isset($authorItem->id)) {
90
-                return '<a href="https://example.org/author/' . $authorItem->id . '">' . $renderedText . '</a>';
90
+                return '<a href="https://example.org/author/'.$authorItem->id.'">'.$renderedText.'</a>';
91 91
             }
92 92
             return $renderedText;
93 93
         },
94 94
         "title" => function($cslItem, $renderedText) {
95
-            return '<a href="https://example.org/publication/' . $cslItem->id . '">' . $renderedText . '</a>';
95
+            return '<a href="https://example.org/publication/'.$cslItem->id.'">'.$renderedText.'</a>';
96 96
         },
97 97
         "csl-entry" => function($cslItem, $renderedText) {
98
-            return '<a id="' . $cslItem->id .'" href="#' . $cslItem->id .'"></a>' . $renderedText;
98
+            return '<a id="'.$cslItem->id.'" href="#'.$cslItem->id.'"></a>'.$renderedText;
99 99
         }
100 100
     ],
101 101
     "citation" => [
102 102
         "citation-number" => function($cslItem, $renderedText) {
103
-            return '<a href="#' . $cslItem->id .'">'.$renderedText.'</a>';
103
+            return '<a href="#'.$cslItem->id.'">'.$renderedText.'</a>';
104 104
         }
105 105
     ]
106 106
 ]);
Please login to merge, or discard this patch.
src/Styles/QuotesTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
             $openQuote = CiteProc::getContext()->getLocale()->filter("terms", "open-quote")->single;
47 47
             $closeQuote = CiteProc::getContext()->getLocale()->filter("terms", "close-quote")->single;
48 48
             $text = $this->replaceOuterQuotes($text, $openQuote, $closeQuote);
49
-            return $openQuote . $text . $closeQuote;
49
+            return $openQuote.$text.$closeQuote;
50 50
         }
51 51
         return $text;
52 52
     }
Please login to merge, or discard this patch.
src/Styles/ConsecutivePunctuationCharacterTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
         if (empty($punctuationSign) || preg_match("/^\s+$/", $punctuationSign)) {
43 43
             return $subject;
44 44
         }
45
-        $pattern = '/' . preg_quote(trim($punctuationSign)) . '{2,}/';
45
+        $pattern = '/'.preg_quote(trim($punctuationSign)).'{2,}/';
46 46
         if (preg_match($pattern, $subject)) {
47 47
             $res = preg_replace($pattern, $punctuationSign, $subject);
48 48
             return $res;
Please login to merge, or discard this patch.
src/Styles/Css/CssRule.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@
 block discarded – undo
64 64
      */
65 65
     public function __toString()
66 66
     {
67
-        $directives = "\t" . implode("\n\t", $this->directives->toArray());
68
-        return $this->selectorType . $this->selector . " {\n" . $directives . "\n}\n";
67
+        $directives = "\t".implode("\n\t", $this->directives->toArray());
68
+        return $this->selectorType.$this->selector." {\n".$directives."\n}\n";
69 69
     }
70 70
 }
71 71
\ No newline at end of file
Please login to merge, or discard this patch.
src/Styles/Css/CssStyle.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -60,11 +60,11 @@
 block discarded – undo
60 60
         if ($lineSpacing || $entrySpacing || $hangingIndent) {
61 61
             $rule = $this->cssRules->getRule(".csl-entry");
62 62
             if (!empty($lineSpacing)) {
63
-                $rule->addDirective("line-height", intval($lineSpacing) . "em");
63
+                $rule->addDirective("line-height", intval($lineSpacing)."em");
64 64
             }
65 65
 
66 66
             if (!empty($entrySpacing)) {
67
-                $rule->addDirective("margin-bottom", intval($entrySpacing) . "em");
67
+                $rule->addDirective("margin-bottom", intval($entrySpacing)."em");
68 68
             }
69 69
 
70 70
             if (!empty($hangingIndent)) {
Please login to merge, or discard this patch.
src/Styles/AffixesTrait.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -84,12 +84,12 @@
 block discarded – undo
84 84
                 $lastChar = mb_substr($text, -1, 1);
85 85
                 if ($closeQuote === $lastChar) { // last char is closing quote?
86 86
                     $text = mb_substr($text, 0, mb_strlen($text) - 1); //set suffix before
87
-                    return $text . $suffix . $lastChar;
87
+                    return $text.$suffix.$lastChar;
88 88
                 }
89 89
             }
90 90
         }
91 91
 
92
-        return $prefix . $text . $suffix;
92
+        return $prefix.$text.$suffix;
93 93
     }
94 94
 
95 95
     /**
Please login to merge, or discard this patch.
src/Styles/FormattingTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -90,7 +90,7 @@
 block discarded – undo
90 90
                 }
91 91
             }
92 92
             if (!empty($format)) {
93
-                $text = '<span style="' . $format . '">' . $text . '</span>';
93
+                $text = '<span style="'.$format.'">'.$text.'</span>';
94 94
             }
95 95
         }
96 96
         return $text;
Please login to merge, or discard this patch.
src/Styles/DisplayTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@
 block discarded – undo
55 55
         if (!in_array($this->display, self::$allowedValues)) {
56 56
             return $text;
57 57
         }
58
-        $divStyle = "class=\"csl-" . $this->display . "\"";
58
+        $divStyle = "class=\"csl-".$this->display."\"";
59 59
         return "<div $divStyle>$text</div>";
60 60
     }
61 61
 }
62 62
\ No newline at end of file
Please login to merge, or discard this patch.