Problem/Motivation
I want to redirect to a PDF file.
However in FieldRedirectionFormatter::shouldDeny() getRouteName() is called on the $redirect_url resulting in an UnexpectedValueException.
Steps to reproduce
Try to redirect to a pdf.
Proposed resolution
Only call getRouteName if url is routed. E.g.
$route_name = $redirect_url->isRouted() ? $redirect_url->getRouteName() : NULL;
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | field_redirection_is_routed_check.patch | 824 bytes | dahousecat |
Issue fork field_redirection-3541084
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3541084-should-check-if
changes, plain diff MR !7
Comments
Comment #2
dahousecat commentedComment #7
larowlanThanks. fixed, tagging 8.x-2.4