for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace EricMakesStuff\ServerMonitor\Notifications\Senders;
use Illuminate\Contracts\Config\Repository;
use EricMakesStuff\ServerMonitor\Notifications\BaseSender;
class Pushover extends BaseSender
{
/** @var array */
protected $config;
/**
* @param Repository $config
*/
public function __construct(Repository $config)
$this->config = $config->get('server-monitor.notifications.pushover');
$config->get('server-mon...otifications.pushover')
*
array
$config
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..
}
public function send()
curl_setopt_array($ch = curl_init(), [
CURLOPT_URL => 'https://api.pushover.net/1/messages.json',
CURLOPT_POSTFIELDS => [
'token' => $this->config['token'],
'user' => $this->config['user'],
'title' => $this->subject,
'message' => $this->message,
'sound' => $this->type === static::TYPE_SUCCESS ? 'pushover' : 'siren',
],
CURLOPT_SAFE_UPLOAD => true,
CURLOPT_RETURNTRANSFER => true,
]);
curl_exec($ch);
curl_close($ch);
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..