-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Inconsistent results of phorum_api_user_check_access call with 3 parameters #892
Comments
Please give some full examples of whats going wrong and what you'd expect. |
I encountered such calls in module Forum Subscriptions: It turned out those calls caused problems for sending queue mails by cron. I went through the rest of the code and found calls to the function mostly with 1 or 2 parameters. So, it was used to check access for current Phorum user. Here is an example to illustrate the issue in my setup for a particular user. phorum_db_user_get(370, true) yields phorum_api_user_check_access(PHORUM_USER_ALLOW_READ, PHORUM_ACCESS_LIST, 370) gives Next, und voila! Looking forward to your reply. |
Thanks for the reproduce case. Please try the fix from the commit given. |
Thanks for your commit. |
This modification also produces some unexpected behavior.
/**
|
More details about the unexpected behavior happening now would be useful. |
I recently found out that phorum_api_user_check_access calls with 3 parameters don't give the correct results as expected from let's say
phorum_db_user_get($user_id, true)
in 'forum_permissions' and 'group_permissions'.
I tested with these calls:
phorum_api_user_check_access(PHORUM_USER_ALLOW_READ, $forum_id, $user_id)
and
phorum_api_user_check_access(PHORUM_USER_ALLOW_READ, PHORUM_ACCESS_LIST, $user_id).
Would you please test this issue and report?
The text was updated successfully, but these errors were encountered: