Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not crash when generating URLs with arrays as parameters #2018

Merged
merged 1 commit into from
May 15, 2018
Merged

Do not crash when generating URLs with arrays as parameters #2018

merged 1 commit into from
May 15, 2018

Conversation

cweiske
Copy link
Contributor

@cweiske cweiske commented May 14, 2018

When using a default image derivatives (#1979) setting like

images:
  defaults:
    derivatives: [300,600]

then Grav crashes when a video gets embedded.
The following error occurs:

rawurlencode() expects parameter 1 to be string, array given
system/src/Grav/Common/Page/Medium/Medium.php:521

This patch encodes array URL parameters correctly.

When using a default image derivatives (#1979) setting like

  images:
    defaults:
      derivatives: [300,600]

then Grav crashes when a video gets embedded.
The following error occurs:

  rawurlencode() expects parameter 1 to be string, array given
  system/src/Grav/Common/Page/Medium/Medium.php:521

This patch encodes array URL parameters correctly.
@rhukster rhukster merged commit 7f90ad8 into getgrav:develop May 15, 2018
@rhukster
Copy link
Member

cheers..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants