Verified Commit a3460c4f authored by Dave Long's avatar Dave Long
Browse files

task: #3549727 Fix LongLineDeclaration in module Controller, Hook and Database directories

By: quietone
By: longwave
parent e05c7682
Loading
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -53,7 +53,10 @@ public function setNoJsCookie(Request $request) {
    $response = new LocalRedirectResponse($request->query->get('destination'));
    // Set cookie without httpOnly, so that JavaScript can delete it.
    $response->headers->setCookie(new Cookie(BigPipeStrategy::NOJS_COOKIE, TRUE, 0, '/', NULL, FALSE, FALSE, FALSE, NULL));
    $response->addCacheableDependency((new CacheableMetadata())->addCacheContexts(['cookies:' . BigPipeStrategy::NOJS_COOKIE, 'session.exists']));
    $response->addCacheableDependency((new CacheableMetadata())->addCacheContexts([
      'cookies:' . BigPipeStrategy::NOJS_COOKIE,
      'session.exists',
    ]));
    return $response;
  }

+5 −1
Original line number Diff line number Diff line
@@ -217,7 +217,11 @@ public function rebuild(): void {
          // Disable blocks in invalid regions.
          if (!isset($regions[$block->getRegion()])) {
            if ($block->status()) {
              \Drupal::messenger()->addWarning($this->t('The block %info was assigned to the invalid region %region and has been disabled.', ['%info' => $block_id, '%region' => $block->getRegion()]));
              \Drupal::messenger()
                ->addWarning($this->t('The block %info was assigned to the invalid region %region and has been disabled.', [
                  '%info' => $block_id,
                  '%region' => $block->getRegion(),
                ]));
            }
            $block->setRegion(system_default_region($theme))->disable()->save();
          }
+4 −1
Original line number Diff line number Diff line
@@ -31,7 +31,10 @@ public function help($route_name, RouteMatchInterface $route_match): ?string {
        $field_ui = \Drupal::moduleHandler()->moduleExists('field_ui') ? Url::fromRoute('help.page', ['name' => 'field_ui'])->toString() : '#';
        $output = '';
        $output .= '<h2>' . $this->t('About') . '</h2>';
        $output .= '<p>' . $this->t('The Block Content module manages the creation, editing, and deletion of content blocks. Content blocks are field-able content entities managed by the <a href=":field">Field module</a>. For more information, see the <a href=":block-content">online documentation for the Block Content module</a>.', [':block-content' => 'https://www.drupal.org/documentation/modules/block_content', ':field' => Url::fromRoute('help.page', ['name' => 'field'])->toString()]) . '</p>';
        $output .= '<p>' . $this->t('The Block Content module manages the creation, editing, and deletion of content blocks. Content blocks are field-able content entities managed by the <a href=":field">Field module</a>. For more information, see the <a href=":block-content">online documentation for the Block Content module</a>.', [
          ':block-content' => 'https://www.drupal.org/documentation/modules/block_content',
          ':field' => Url::fromRoute('help.page', ['name' => 'field'])->toString(),
        ]) . '</p>';
        $output .= '<h2>' . $this->t('Uses') . '</h2>';
        $output .= '<dl>';
        $output .= '<dt>' . $this->t('Creating and managing block types') . '</dt>';
+5 −1
Original line number Diff line number Diff line
@@ -305,7 +305,11 @@ public function libraryInfoAlter(&$libraries, $extension): void {
            $langcode = basename($file, '.js');
            // Only add languages that Drupal can understands.
            if (in_array($langcode, $ckeditor_langcodes)) {
              $library['js']["{$dirname}/translations/{$langcode}.js"] = ['ckeditor5_langcode' => $langcode, 'minified' => TRUE, 'preprocess' => TRUE];
              $library['js']["{$dirname}/translations/{$langcode}.js"] = [
                'ckeditor5_langcode' => $langcode,
                'minified' => TRUE,
                'preprocess' => TRUE,
              ];
            }
          }
        }
+4 −1
Original line number Diff line number Diff line
@@ -111,7 +111,10 @@ public function preprocessComment(array &$variables): void {
        $variables['user_picture'] = [];
      }

      $variables['submitted'] = $this->t('Submitted by @username on @datetime', ['@username' => $variables['author'], '@datetime' => $variables['created']]);
      $variables['submitted'] = $this->t('Submitted by @username on @datetime', [
        '@username' => $variables['author'],
        '@datetime' => $variables['created'],
      ]);
    }

    if (isset($comment->in_preview)) {
Loading