Skip to content

Commit

Permalink
ENH Provide hook for updating the parent used for absoluteURL (#10168)
Browse files Browse the repository at this point in the history
One use case for this that I've run into a few times is for sending emails using a queued job from the CLI.
  • Loading branch information
GuySartorelli authored Jan 31, 2022
1 parent 83156dd commit fc2160f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Control/Director.php
Original file line number Diff line number Diff line change
Expand Up @@ -470,6 +470,7 @@ public static function absoluteURL($url, $relativeParent = self::BASE)
// Default to respecting site base_url
$parent = self::absoluteBaseURL();
}
static::singleton()->extend('updateAbsoluteURLParent', $parent);

// Map empty urls to relative slash and join to base
if (empty($url) || $url === '.' || $url === './') {
Expand Down

0 comments on commit fc2160f

Please sign in to comment.