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

Docs: Set PDO attributes after variable has been assigned #2334

Merged
merged 1 commit into from
Dec 9, 2024

Conversation

piotr-cz
Copy link
Contributor

@piotr-cz piotr-cz commented Dec 9, 2024

As in PR title

@dereuromark
Copy link
Member

why?

@MasterOdin MasterOdin merged commit 1b64777 into cakephp:0.x Dec 9, 2024
12 checks passed
@MasterOdin
Copy link
Member

MasterOdin commented Dec 9, 2024

Thanks for the contribution @piotr-cz.

@dereuromark Before this change, if using that example, then the line doing $this->pdo->setAttribute would result in a fatal error as $this->pdo had not yet been assigned (it was happening after). Now it'll work as expected. 😄

@dereuromark
Copy link
Member

Sry the diff looked differently for me so I saw it being accessed before Set.
Makes sense as in this pr 👍

@piotr-cz piotr-cz deleted the docs/fix-variable-order branch December 10, 2024 08:11
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.

3 participants