Browse Source

Fix PHPCS errors.

MNPALS-2.x
Alexander O'Neill 1 year ago committed by Rosie Le Faive
parent
commit
9f5eceea07
  1. 11
      modules/islandora_iiif/src/Plugin/views/style/IIIFManifest.php

11
modules/islandora_iiif/src/Plugin/views/style/IIIFManifest.php

@ -324,14 +324,15 @@ class IIIFManifest extends StylePluginBase {
* *
* @param \Drupal\Core\Entity\EntityInterface $entity * @param \Drupal\Core\Entity\EntityInterface $entity
* The entity at the current row. * The entity at the current row.
* @param int $delta * @param \Drupal\views\ResultRow $row
*. The delta in case there are multiple canvases on one media. * Result row. * @param int $delta
* * The delta in case there are multiple canvases on one media.
* @return String|FALSE *
* @return string|false
* The absolute URL of the current row's structured text, * The absolute URL of the current row's structured text,
* or FALSE if none. * or FALSE if none.
*/ */
protected function getOcrUrl(EntityInterface $entity, $row, $delta) { protected function getOcrUrl(EntityInterface $entity, ResultRow $row, $delta) {
$ocr_url = FALSE; $ocr_url = FALSE;
$iiif_ocr_file_field = !empty($this->options['iiif_ocr_file_field']) ? array_filter(array_values($this->options['iiif_ocr_file_field'])) : []; $iiif_ocr_file_field = !empty($this->options['iiif_ocr_file_field']) ? array_filter(array_values($this->options['iiif_ocr_file_field'])) : [];
$ocrField = count($iiif_ocr_file_field) > 0 ? $this->view->field[$iiif_ocr_file_field[0]] : NULL; $ocrField = count($iiif_ocr_file_field) > 0 ? $this->view->field[$iiif_ocr_file_field[0]] : NULL;

Loading…
Cancel
Save