1
0
mirror of https://github.com/flarum/core.git synced 2025-10-19 02:36:08 +02:00

Merge branch 'master' into 1236-database-changes

This commit is contained in:
Toby Zerner
2018-08-24 17:03:50 +09:30
26 changed files with 263 additions and 143 deletions

View File

@@ -277,7 +277,7 @@ class Gate implements GateContract
$result = call_user_func_array([$instance, 'before'], $beforeArguments);
// If we recieved a non-null result from the before method, we will return it
// If we received a non-null result from the before method, we will return it
// as the result of a check. This allows developers to override the checks
// in the policy and return a result for all rules defined in the class.
if (! is_null($result)) {

View File

@@ -38,7 +38,7 @@ class UserPolicy extends AbstractPolicy
*/
public function find(User $actor, Builder $query)
{
if ($actor->cannot('viewDiscussions')) {
if ($actor->cannot('viewUserList')) {
$query->whereRaw('FALSE');
}
}