Issues (38)

Services/AzineContactSorter.php (1 issue)

1
<?php
2
3
namespace Azine\HybridAuthBundle\Services;
4
5
use Azine\HybridAuthBundle\Entity\UserContact;
6
7
class AzineContactSorter implements ContactSorter
8
{
9
    /**
10
     * In this default implementation, all the contacts are sorted in
11
     * alphabetic order by their lastName.
12
     *
13
     * @param UserContact $a
14
     *
15 1
     * @return UserContact $b
16 1
     */
17
    public function compare(UserContact $a, UserContact $b)
18
    {
19
        return strnatcasecmp($a->lastName, $b->lastName);
0 ignored issues
show
Bug Best Practice introduced by
The expression return strnatcasecmp($a->lastName, $b->lastName) returns the type integer which is incompatible with the documented return type Azine\HybridAuthBundle\Entity\UserContact.
Loading history...
20
    }
21
}
22