In the file : core/lib/Drupal/Core/Url.php , function setUnrouted in class Url is not returning $this. But in comment doc already documented @returng as $this.

I have added the return $this; to the function .

here is the changes,

@@ -515,6 +515,7 @@ protected function setUnrouted() {
     // Set empty route name and parameters.
     $this->routeName = NULL;
     $this->routeParameters = array();
+    return $this;
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rakesh.gectcr created an issue. See original summary.

tim.plunkett’s picture

Status: Needs review » Reviewed & tested by the community

Thanks!

chx’s picture

Issue tags: +Quickfix
tim.plunkett’s picture

Issue tags: +rc target triage

I almost tagged this rc eligible, but I guess it's not.
But it's a oneline change to a protected method on a value object, it's very non-disruptive.

Wim Leers’s picture

Yep, plain bugfix. Was also tempted to mark this rc eligible.

alexpott’s picture

Issue tags: -rc target triage +rc target

@catch and I have discuss and agree that this makes sense to do during RC.

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed ec470dd and pushed to 8.0.x. Thanks!

  • alexpott committed 8bd6cea on 8.0.x
    Issue #2605280 by rakesh.gectcr: Missing return $this in Url::...

Status: Fixed » Closed (fixed)

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