Commit ca4ce861 authored by totten's avatar totten

CRM_Utils_Hook::alterRedirect - Pass URL by reference

PSR-7 specifies that the `UriInterface` is immutable.  There are methods
like `withQuery(...)` which generate a *new instance*.

For the hook to support altering the URL, you must be able to replace the
`$url` with a newer instance.
parent f9bdf062
......@@ -1649,7 +1649,7 @@ abstract class CRM_Utils_Hook {
* @return null
* the return value is ignored
*/
public static function alterRedirect($url, &$context) {
public static function alterRedirect(&$url, &$context) {
return self::singleton()->invoke(array('url', 'context'), $url,
$context, self::$_nullObject,
self::$_nullObject, self::$_nullObject, self::$_nullObject,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment