-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[Ldap] Fixed issue with legacy client initialisation #18944
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
Conversation
Any way to add some tests? |
Sure! I'll try to find some time for this tomorrow |
@csarrazi This fix worked for me. Thanks |
@@ -24,13 +24,22 @@ | |||
|
|||
public function __construct($host = null, $port = 389, $version = 3, $useSsl = false, $useStartTls = false, $optReferrals = false, LdapInterface $ldap = null) | |||
{ | |||
if ((bool) $useSsl) { |
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.
no need to cast explicitly here
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.
True. However this was kept to ensure the previous behaviour.
I can remove the cast, if needed.
btw, this class is missing its deprecation warning |
You mean in the constructor, right? |
@csarrazi stof means after the namespace declaration. See |
Ok. I'll check this tonight! Thanks for the info @nicolas-grekas! |
@nicolas-grekas @stof Done. |
@@ -11,6 +11,8 @@ | |||
|
|||
namespace Symfony\Component\Ldap; | |||
|
|||
@trigger_error('The '.__NAMESPACE__.'\LdapClient class is deprecated since version 3.1 and will be removed in 4.0. Use directly the Ldap class instead.', E_USER_DEPRECATED); |
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.
Use the Ldap class directly instead.
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.
Done
👍 |
It will be okay to remove them for 4.0. The
|
Thank you @csarrazi. |
…razi) This PR was merged into the 3.1 branch. Discussion ---------- [Ldap] Fixed issue with legacy client initialisation | Q | A | ------------- | --- | Branch? | 3.1 | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | #18725 (comment) | License | MIT | Doc PR | Thanks @uvups for noticing this. Commits ------- 6804efe Fixed issue with legacy client initialization
Thanks @uvups for noticing this.