Commit f85dd2ca authored by catch's avatar catch
Browse files

fix: #3557157...

fix: #3557157 \Drupal\views\Entity\Render\TranslationLanguageRenderer::getLangcodeTable() causes deprecations on PHP 8.5

By: @alexpott
(cherry picked from commit 48563d7a)
parent ee60b69f
Loading
Loading
Loading
Loading
Loading
+6 −3
Original line number Diff line number Diff line
@@ -42,8 +42,9 @@ public function query(QueryPluginBase $query, $relationship = NULL) {
   *
   * @param \Drupal\views\Plugin\views\query\QueryPluginBase $query
   *   The query being executed.
   * @param string $relationship
   *   The relationship used by the entity type.
   * @param string|null $relationship
   *   The relationship used by the entity type. NULL if there is no
   *   relationship.
   *
   * @return string
   *   A table name.
@@ -60,7 +61,9 @@ protected function getLangcodeTable(QueryPluginBase $query, $relationship) {
    // use the revision table or the revision data table, depending on which one
    // is being used as query base table.
    if ($this->entityType->isRevisionable()) {
      $query_base_table = $query->relationships[$relationship]['base'] ??
      // $relationship is not always set, so a default value is used to fallback
      // to the view's base table.
      $query_base_table = $query->relationships[$relationship ?? '']['base'] ??
        $this->view->storage->get('base_table');
      $revision_table = $storage->getRevisionTable();
      $revision_data_table = $storage->getRevisionDataTable();