src/Message/Message.php
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
Client $slackClient,
array $data,
string $formattedText,
User $user = null,
Channel $channel)
Return type of getChannel()
is undeclared type \Slack\Channel
Open
Open
public function getChannel() : Channel
- Exclude checks
Property \Nopolabs\Yabot\Message\Message->channel
has undeclared type \Slack\Channel
Open
Open
private $channel;
- Exclude checks
Assigning ?\Slack\User
to property but \Nopolabs\Yabot\Message\Message->user
is \Slack\User
Open
Open
$this->user = $user;
- Exclude checks
Parameter $user
has undeclared type ?\Slack\User
Open
Open
public function __construct(
- Exclude checks
Reference to instance property data
from undeclared class \Slack\User
Open
Open
return (bool) $this->user->data['is_bot'];
- Exclude checks
Parameter $channel
has undeclared type \Slack\Channel
Open
Open
public function __construct(
- Exclude checks
Reference to instance property data
from undeclared class \Slack\User
Open
Open
if (isset($this->user->data['is_bot'])) {
- Exclude checks
Call to method getUsername
from undeclared class \Slack\User
Open
Open
return $user ? $user->getUsername() : ($this->isBot() ? 'unknown-bot' : 'unknown-user');
- Exclude checks
Call to method getName
from undeclared class \Slack\Channel
Open
Open
return $this->getChannel()->getName();
- Exclude checks
Property \Nopolabs\Yabot\Message\Message->user
has undeclared type \Slack\User
Open
Open
private $user;
- Exclude checks
Required argument follows optional Open
Open
public function __construct(
- Exclude checks
The closing parenthesis of a multi-line function declaration must be on a new line Open
Open
Channel $channel)
- Exclude checks
The closing parenthesis and the opening brace of a multi-line function declaration must be on the same line Open
Open
{
- Exclude checks
Expected 1 newline at end of file; 0 found Open
Open
}
- Exclude checks