The expression array_search($logD, $this->getArrayCopy()); of type false|integer|string adds the type string to the return on line 22 which is incompatible with the return type declared by the interface FilmTools\Commons\SearchableInterface::search of type integer|false.