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

Avoid PHP errors when the LDAP attribute is not found #29180

Merged
merged 4 commits into from
Oct 15, 2021

Conversation

come-nc
Copy link
Contributor

@come-nc come-nc commented Oct 12, 2021

Should fix #27798

This will avoid the PHP error. It will still be an error because the ldap attribute used to name the user internally cannot be found or is empty, but it won’t be a PHP error anymore.

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Copy link
Member

@blizzz blizzz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just that one thing pointed out :)

apps/user_ldap/lib/Jobs/Sync.php Outdated Show resolved Hide resolved
…_LDAP\Access

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
@come-nc come-nc force-pushed the bug/27798/fix-php-error-in-ldap-access branch from 9e64275 to d189a23 Compare October 14, 2021 07:25
@come-nc
Copy link
Contributor Author

come-nc commented Oct 14, 2021

This is again ready for review/merge, I did what I could to improve the situation on the logger front, the rest will need a DI refactor of the user_ldap application.

@come-nc come-nc force-pushed the bug/27798/fix-php-error-in-ldap-access branch from 3bc2b97 to bb17438 Compare October 14, 2021 11:43
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
@come-nc come-nc force-pushed the bug/27798/fix-php-error-in-ldap-access branch from bb17438 to f9e6f2e Compare October 14, 2021 12:12
@skjnldsv skjnldsv merged commit 8df577b into master Oct 15, 2021
@skjnldsv skjnldsv deleted the bug/27798/fix-php-error-in-ldap-access branch October 15, 2021 09:03
@welcome
Copy link

welcome bot commented Oct 15, 2021

Thanks for your first pull request and welcome to the community! Feel free to keep them coming! If you are looking for issues to tackle then have a look at this selection: https://github.com/nextcloud/server/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22

@come-nc
Copy link
Contributor Author

come-nc commented Oct 19, 2021

/backport to stable22

@come-nc
Copy link
Contributor Author

come-nc commented Oct 19, 2021

/backport to stable21

@come-nc
Copy link
Contributor Author

come-nc commented Oct 19, 2021

/backport to stable20

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

Successfully merging this pull request may close these issues.

Cron LDAP: Trying to access array offset on value of type bool at /apps/user_ldap/lib/Access.php
5 participants