mirror of
https://github.com/usetrmnl/byos_laravel.git
synced 2026-01-13 15:07:49 +00:00
fix: update_firmware flag is only returned once to avoid upgrade loop
chore: fix code style
This commit is contained in:
parent
5367fc8a64
commit
6e5e4cd633
4 changed files with 59 additions and 1 deletions
|
|
@ -71,6 +71,14 @@ class Device extends Model
|
|||
return null;
|
||||
}
|
||||
|
||||
public function resetUpdateFirmwareFlag(): void
|
||||
{
|
||||
if ($this->proxy_cloud_response) {
|
||||
$this->proxy_cloud_response = array_merge($this->proxy_cloud_response, ['update_firmware' => false]);
|
||||
$this->save();
|
||||
}
|
||||
}
|
||||
|
||||
public function playlists(): HasMany
|
||||
{
|
||||
return $this->hasMany(Playlist::class);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue