UrlGenerator::setBasePath(), UrlGenerator::setBaseUrl(), and UrlGenerator::setScriptPath() are all redundant and we should remove UrlGenerator::updateFromRequest()

Comments

alexpott’s picture

Status: Active » Needs review
StatusFileSize
new10.09 KB

Status: Needs review » Needs work

The last submitted patch, 1: 2343607.1.patch, failed testing.

alexpott’s picture

Status: Needs work » Needs review
StatusFileSize
new1.47 KB
new9.95 KB

Fixed failing tests

Status: Needs review » Needs work

The last submitted patch, 3: 2343607.3.patch, failed testing.

dawehner’s picture

Status: Needs work » Needs review
StatusFileSize
new12.24 KB
new3.35 KB

Here are the test fixes, took me a little while, though.

alexpott’s picture

StatusFileSize
new14.82 KB
new2.57 KB

Fixed installer tests

dawehner’s picture

Just a quick nitpick!

+++ b/core/lib/Drupal/Core/Routing/NullGenerator.php
@@ -19,17 +20,8 @@ class NullGenerator extends UrlGenerator {
   /**
    * Override the parent constructor.
    */
...
+  public function __construct(RequestStack $request_stack) {
+    $this->requestStack = $request_stack;
   }

Would be great to just keep proper docs.

The last submitted patch, 5: 2343607-5.patch, failed testing.

Status: Needs review » Needs work

The last submitted patch, 6: 2343607.6.patch, failed testing.

alexpott’s picture

Status: Needs work » Needs review
StatusFileSize
new2.12 KB
new16.49 KB

Fixing the test - which is actually broken atm - this does not break it anymore than it already is see #2265099: Cleanup SessionHttpsTest and fix redirect to non-existing URL after POST requests

catch’s picture

Looks great.

dawehner’s picture

Status: Needs review » Reviewed & tested by the community

+1

catch’s picture

Status: Reviewed & tested by the community » Fixed

Committed/pushed to 8.0.x, thanks!

  • catch committed 03aa670 on 8.0.x
    Issue #2343607 by alexpott, dawehner: Cleanup UrlGenerator.
    

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.