@@ -71,7 +71,7 @@ discard block |
||
| 71 | 71 | foreach ($this->conditionVariables as $variable) { |
| 72 | 72 | $conditionMatched |= $this->matchForVariable($variable, $value); |
| 73 | 73 | } |
| 74 | - return (bool)$conditionMatched; |
|
| 74 | + return (bool) $conditionMatched; |
|
| 75 | 75 | } |
| 76 | 76 | |
| 77 | 77 | private function matchAll($value) |
@@ -80,6 +80,6 @@ discard block |
||
| 80 | 80 | foreach ($this->conditionVariables as $variable) { |
| 81 | 81 | $conditionMatched &= $this->matchForVariable($variable, $value); |
| 82 | 82 | } |
| 83 | - return (bool)$conditionMatched; |
|
| 83 | + return (bool) $conditionMatched; |
|
| 84 | 84 | } |
| 85 | 85 | } |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | { |
| 30 | 30 | $dp = $dateParts->toArray(); |
| 31 | 31 | $dateParts_ = []; |
| 32 | - array_walk($dp, function ($datePart, $key) use (&$dateParts_) { |
|
| 32 | + array_walk($dp, function($datePart, $key) use (&$dateParts_) { |
|
| 33 | 33 | if (strpos($key, "year") !== false || strpos($key, "month") !== false) { |
| 34 | 34 | $dateParts_["yearmonth"][] = $datePart; |
| 35 | 35 | } |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | { |
| 30 | 30 | $dp = $dateParts->toArray(); |
| 31 | 31 | $dateParts_ = []; |
| 32 | - array_walk($dp, function ($datePart, $key) use (&$dateParts_) { |
|
| 32 | + array_walk($dp, function($datePart, $key) use (&$dateParts_) { |
|
| 33 | 33 | if (strpos($key, "year") !== false || strpos($key, "day") !== false) { |
| 34 | 34 | $dateParts_["yearday"][] = $datePart; |
| 35 | 35 | } |
@@ -28,7 +28,7 @@ |
||
| 28 | 28 | { |
| 29 | 29 | $dp = $dateParts->toArray(); |
| 30 | 30 | $dateParts_ = []; |
| 31 | - array_walk($dp, function ($datePart, $key) use (&$dateParts_) { |
|
| 31 | + array_walk($dp, function($datePart, $key) use (&$dateParts_) { |
|
| 32 | 32 | //$bit = sprintf("%03d", decbin($differentParts)); |
| 33 | 33 | if (strpos($key, "month") !== false || strpos($key, "day") !== false) { |
| 34 | 34 | $dateParts_["monthday"][] = $datePart; |
@@ -151,7 +151,7 @@ |
||
| 151 | 151 | public function flatten($array) |
| 152 | 152 | { |
| 153 | 153 | $returnArray = []; |
| 154 | - array_walk_recursive($array, function ($a) use (&$returnArray) { |
|
| 154 | + array_walk_recursive($array, function($a) use (&$returnArray) { |
|
| 155 | 155 | $returnArray[] = $a; |
| 156 | 156 | }); |
| 157 | 157 | return $returnArray; |
@@ -430,7 +430,7 @@ |
||
| 430 | 430 | |
| 431 | 431 | public function getCitationItemById($id) |
| 432 | 432 | { |
| 433 | - return $this->citationItems->filter(function ($item) use ($id) { |
|
| 433 | + return $this->citationItems->filter(function($item) use ($id) { |
|
| 434 | 434 | return $item->id === $id; |
| 435 | 435 | })->current(); |
| 436 | 436 | } |
@@ -39,7 +39,7 @@ |
||
| 39 | 39 | public static function mapLocatorLabelToRenderVariable($locatorTerm) |
| 40 | 40 | { |
| 41 | 41 | if ($locatorTerm instanceof Locator) { |
| 42 | - $locatorTerm = (string)$locatorTerm; |
|
| 42 | + $locatorTerm = (string) $locatorTerm; |
|
| 43 | 43 | } |
| 44 | 44 | return |
| 45 | 45 | array_key_exists($locatorTerm, self::LABEL_TO_VARIABLE_MAP) ? |
@@ -53,12 +53,12 @@ discard block |
||
| 53 | 53 | */ |
| 54 | 54 | public function __construct(Config\Locale $localeConfig, $xmlString = null) |
| 55 | 55 | { |
| 56 | - $this->language = (string)$localeConfig; |
|
| 56 | + $this->language = (string) $localeConfig; |
|
| 57 | 57 | |
| 58 | 58 | if (!empty($xmlString)) { |
| 59 | 59 | $this->localeXml = new SimpleXMLElement($xmlString); |
| 60 | 60 | } else { |
| 61 | - $this->localeXml = new SimpleXMLElement(loadLocales((string)$localeConfig)); |
|
| 61 | + $this->localeXml = new SimpleXMLElement(loadLocales((string) $localeConfig)); |
|
| 62 | 62 | } |
| 63 | 63 | |
| 64 | 64 | $this->initLocaleXmlParser(); |
@@ -122,7 +122,7 @@ discard block |
||
| 122 | 122 | //filter by form |
| 123 | 123 | if ($type !== "options") { |
| 124 | 124 | /** @var Term $value */ |
| 125 | - $array = array_filter($array, function ($term) use ($form) { |
|
| 125 | + $array = array_filter($array, function($term) use ($form) { |
|
| 126 | 126 | return $term->form === $form; |
| 127 | 127 | }); |
| 128 | 128 | } |
@@ -37,7 +37,7 @@ |
||
| 37 | 37 | return $text; |
| 38 | 38 | } |
| 39 | 39 | |
| 40 | - switch ((string)$this->textCase) { |
|
| 40 | + switch ((string) $this->textCase) { |
|
| 41 | 41 | case TextCase::UPPERCASE: |
| 42 | 42 | $text = $this->keepNoCase(mb_strtoupper($text), $text); |
| 43 | 43 | break; |