Bug Report #4651

Request::uri() throws exception instead of returning a valid uri (docs obsolete)

Added by Samnan Akhoond over 1 year ago. Updated 5 months ago.

Status:ClosedStart date:11/07/2012
Priority:NormalDue date:
Assignee:Lorenzo Pisani% Done:

100%

Category:Core
Target version:v3.2.3
Resolution:fixed Points:1

Description

In KO3.2, using the following code would return a valid url to the action 'thanks' in current controller context;

$uri = $this->request->uri( array('action' => 'thanks') );

Upgrading to KO3.3, it throws an exception due to concatenation of strings and array on request.php line 1254

Need to either fix the method's functionality as previous version, or update the docs and specify the right way to regerenrate valid url's through routes (whichever is the right way to do it)

History

#1 Updated by Jeremy Bush over 1 year ago

The documentation should be changed. We can't revert the functionality in a minor version.

#2 Updated by Jeremy Bush over 1 year ago

  • Priority changed from High to Normal
  • Target version set to 3.3.1

#3 Updated by Lorenzo Pisani over 1 year ago

  • Target version changed from 3.3.1 to v3.2.3

This should be in the 3.2 upgrade docs because this change was made there. http://dev.kohanaframework.org/issues/3690

3.2 has never allowed this to be done.

#4 Updated by Jeremy Bush over 1 year ago

  • Target version changed from v3.2.3 to 3.3.1

Request::uri() was actually changed in #3470. In 3.2, it simply returned the Request's uri string:

https://github.com/kohana/core/blob/3.2/master/classes/kohana/request.php#L892

#5 Updated by Lorenzo Pisani over 1 year ago

  • Status changed from New to Assigned
  • Assignee set to Lorenzo Pisani
  • Target version changed from 3.3.1 to v3.2.3

Both changes are missing from 3.2 and 3.3 upgrade docs so I'll start with lowest version :)

#6 Updated by Samuel Demirdjian 5 months ago

https://github.com/kohana/core/pull/468

adds section to the upgrade docs about generating uris

#7 Updated by Lorenzo Pisani 5 months ago

  • Status changed from Assigned to Closed
  • % Done changed from 0 to 100
  • Resolution set to fixed

Merged, thanks!

Also available in: Atom PDF