chore: update dependencies

This commit is contained in:
Benjamin Nussbaum 2025-03-25 13:05:23 +01:00
parent 941305dff6
commit 8eb0b2ccd7
6 changed files with 463 additions and 422 deletions

View file

@ -53,19 +53,21 @@ class Device extends Model
}
}
public function getUpdateFirmwareAttribute() : bool
public function getUpdateFirmwareAttribute(): bool
{
if ($this->proxy_cloud_response && $this->proxy_cloud_response['update_firmware']) {
return true;
}
return false;
}
public function getFirmwareUrlAttribute() : string | null
public function getFirmwareUrlAttribute(): ?string
{
if ($this->proxy_cloud_response && $this->proxy_cloud_response['firmware_url']) {
return $this->proxy_cloud_response['firmware_url'];
}
return null;
}

View file

@ -44,7 +44,7 @@ class Plugin extends Model
if ($this->data_strategy === 'polling' && $this->polling_url) {
// Parse headers from polling_header string
$headers = ['User-Agent' => 'usetrmnl/byos_laravel', 'Accept' => 'application/json'];
if ($this->polling_header) {
$headerLines = explode("\n", trim($this->polling_header));
foreach ($headerLines as $line) {