Issues (18)

src/Builders/Traits/WhereUser.php (2 issues)

Labels
Severity
1
<?php
2
3
namespace Sfneal\Users\Builders\Traits;
4
5
use Sfneal\Users\Builders\Interfaces\WhereUserInterface;
6
7
trait WhereUser
8
{
9
    /**
10
     * Scope query to activity that was performed by a particular user.
11
     *
12
     * @param  int  $user_id
13
     * @return $this|WhereUserInterface
14
     */
15
    public function whereUser(int $user_id)
16
    {
17
        $this->where('user_id', '=', $user_id);
0 ignored issues
show
The method where() does not exist on Sfneal\Users\Builders\Traits\WhereUser. Did you maybe mean whereUser()? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

17
        $this->/** @scrutinizer ignore-call */ 
18
               where('user_id', '=', $user_id);

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
18
19
        return $this;
20
    }
21
22
    /**
23
     * Scope query to activity that was performed by any of the specified users.
24
     *
25
     * @param  array  $user_ids
26
     * @return $this|WhereUserInterface
27
     */
28
    public function whereUserIn(array $user_ids)
29
    {
30
        $this->whereIn('user_id', $user_ids);
0 ignored issues
show
The method whereIn() does not exist on Sfneal\Users\Builders\Traits\WhereUser. Did you maybe mean whereUserIn()? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

30
        $this->/** @scrutinizer ignore-call */ 
31
               whereIn('user_id', $user_ids);

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
31
32
        return $this;
33
    }
34
}
35