Updated static analysis

This commit is contained in:
David Bomba 2023-08-07 15:33:40 +10:00
parent cd7d78d20b
commit b4a682df52
3 changed files with 4 additions and 4 deletions

View File

@ -38,13 +38,13 @@ class VersionCheck implements ShouldQueue
$version_file = trim(@file_get_contents(config('ninja.version_url'))); $version_file = trim(@file_get_contents(config('ninja.version_url')));
if (Ninja::isSelfHost() && $version_file) { if (Ninja::isSelfHost() && $version_file) {
/** @var \App\Models\Account $account **/ Account::query()->whereNotNull('id')->update(['latest_version' => $version_file]);
Account::whereNotNull('id')->update(['latest_version' => $version_file]);
} }
if (Ninja::isSelfHost()) { if (Ninja::isSelfHost()) {
nlog("latest version = {$version_file}"); nlog("latest version = {$version_file}");
/** @var \App\Models\Account $account **/
$account = Account::first(); $account = Account::first();
if (! $account) { if (! $account) {

View File

@ -71,13 +71,12 @@ class WebhookSingle implements ShouldQueue
/** /**
* Execute the job. * Execute the job.
* *
* @return bool
*/ */
public function handle() public function handle()
{ {
MultiDB::setDb($this->db); MultiDB::setDb($this->db);
$subscription = Webhook::with('company')->find($this->subscription_id); $subscription = Webhook::query()->with('company')->find($this->subscription_id);
if ($subscription) { if ($subscription) {
// nlog("firing event ID {$subscription->event_id} company_id {$subscription->company_id}"); // nlog("firing event ID {$subscription->event_id} company_id {$subscription->company_id}");

View File

@ -124,6 +124,7 @@ class CreatePurchaseOrderPdf implements ShouldQueue
/* Catch all in case migration doesn't pass back a valid design */ /* Catch all in case migration doesn't pass back a valid design */
if (!$design) { if (!$design) {
/** @var \App\Models\Design $design */
$design = Design::find(2); $design = Design::find(2);
} }