Conversation
phpcs is failing on a line that I didn't actually change. It also fails on the master branch when I run it locally, but the Travis build is still passing on the github master for some reason - I have no idea why. |
@AD7six is there any chance I can get some feedback on this please? I'm keen for this to be merged in as I want to start using SSL connections for my SMTP gateway config :) |
@@ -239,6 +239,18 @@ protected function parseUrlArray($url) | |||
|
|||
$url = array_merge($this->uriKeys, $url); | |||
|
|||
if (isset($url['host'])) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you chnge this pleas to be
foreach['host', 'user', 'pass'] as $key) {
if (!isset($url[$key]) {
continue;
}
$url[$key] = urldecode($url[$key]);
}
please - I.e. make is so that adding another key (should that be necessary in the future) is just adding to an array rather than copy and paste.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. I didn't want to over-complicate things with a loop, but it will certainly keep things DRYer. I'll change them to foreach.
I missed the notification for this - sorry for the delay. I'm unclear which keys need decoding - but if it doesn't break any tests, I'm assuming it won't break any usage for the moment. |
Thanks =) |
Thanks for merging @AD7six. Could we have a new version tagged so these changes can be pulled in with composer please? |
0.4.0 released =) |
Fix for issue #10 - Add url decoding to dsn parts.
URL
host
,user
andpass
parameters are now encoded and decoded.