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

Added ability generate unsecure URL if current URL is secure #10244

Merged
merged 1 commit into from
Jul 14, 2017
Merged

Added ability generate unsecure URL if current URL is secure #10244

merged 1 commit into from
Jul 14, 2017

Conversation

okorshenko
Copy link
Contributor

@okorshenko okorshenko commented Jul 14, 2017

Description

When calling getUrl from a secure connection ( HTTPS ) with param _secure = false we are getting secure URL instead of unsecured.

Fixed Issues (if relevant)

  1. Unable to generate unsecure URL if current URL is secure #6175: Unable to generate unsecure URL if current URL is secure

Manual testing scenarios

Preconditions

Magento 2 version 2.3.0-dev
Use \Magento\Framework\Url::getUrl() from secure area of the store

###Steps to reproduce

Make sure code is executed in secure area of the store (HTTPS)
Generate URL in code
/**
* @var \Magento\Framework\Url
*/
protected $url;
...
$this->url->getUrl(
'test/test/test',
[
'_secure' => false
]
)

Expected result
http://example.com/test/test/test

Contribution checklist

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds on Travis CI are green)

@okorshenko okorshenko self-assigned this Jul 14, 2017
@okorshenko okorshenko added this to the July 2017 milestone Jul 14, 2017
@magento-team magento-team merged commit 9668c3e into magento:develop Jul 14, 2017
magento-team pushed a commit that referenced this pull request Jul 14, 2017
magento-team pushed a commit that referenced this pull request Jul 14, 2017
magento-team pushed a commit that referenced this pull request Jul 14, 2017
@okorshenko okorshenko deleted the okorshenko-patch-2 branch July 26, 2017 01:37
magento-team pushed a commit that referenced this pull request Oct 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants