diff --git a/VERSION.txt b/VERSION.txt index 9647c2c0f76e..6af1ed16172e 100644 --- a/VERSION.txt +++ b/VERSION.txt @@ -1 +1 @@ -5.10.3 \ No newline at end of file +5.10.4 \ No newline at end of file diff --git a/app/Models/Company.php b/app/Models/Company.php index d1e402ece50b..cdfde34fe883 100644 --- a/app/Models/Company.php +++ b/app/Models/Company.php @@ -112,12 +112,12 @@ use Laracasts\Presenter\PresentableTrait; * @property int $notify_vendor_when_paid * @property int $invoice_task_hours * @property int $deleted_at - * @property string $smtp_username - * @property string $smtp_password - * @property string $smtp_host - * @property string $smtp_port - * @property string $smtp_encryption - * @property string $smtp_local_domain + * @property string|null $smtp_username + * @property string|null $smtp_password + * @property string|null $smtp_host + * @property string|null $smtp_port + * @property string|null $smtp_encryption + * @property string|null $smtp_local_domain * @property boolean $smtp_verify_peer * @property-read \App\Models\Account $account * @property-read \Illuminate\Database\Eloquent\Collection $activities diff --git a/app/Services/Subscription/SubscriptionService.php b/app/Services/Subscription/SubscriptionService.php index 50f2aa792f89..1cc177b68573 100644 --- a/app/Services/Subscription/SubscriptionService.php +++ b/app/Services/Subscription/SubscriptionService.php @@ -1118,7 +1118,7 @@ class SubscriptionService */ public function triggerWebhook($context) { - if (empty($this->subscription->webhook_configuration['post_purchase_url']) || is_null($this->subscription->webhook_configuration['post_purchase_url']) || strlen($this->subscription->webhook_configuration['post_purchase_url']) < 1) { + if (empty($this->subscription->webhook_configuration['post_purchase_url']) || is_null($this->subscription->webhook_configuration['post_purchase_url']) || strlen($this->subscription->webhook_configuration['post_purchase_url']) < 1) { //@phpstan-ignore-line return ["message" => "Success", "status_code" => 200]; } diff --git a/app/Services/Subscription/SubscriptionStatus.php b/app/Services/Subscription/SubscriptionStatus.php index e4252a8dd3bd..baa974be547b 100644 --- a/app/Services/Subscription/SubscriptionStatus.php +++ b/app/Services/Subscription/SubscriptionStatus.php @@ -174,7 +174,7 @@ class SubscriptionStatus extends AbstractService */ private function checkRefundable(): self { - if(!$this->recurring_invoice->subscription->refund_period || (int)$this->recurring_invoice->subscription->refund_period == 0) { + if(!$this->recurring_invoice->subscription->refund_period || (int)$this->recurring_invoice->subscription->refund_period == 0) {//@phpstan-ignore-line return $this->setRefundable(false); } diff --git a/app/Services/Template/TemplateService.php b/app/Services/Template/TemplateService.php index 44f02d9b82a0..2a7149d6af61 100644 --- a/app/Services/Template/TemplateService.php +++ b/app/Services/Template/TemplateService.php @@ -436,11 +436,11 @@ class TemplateService } match ($key) { - 'variables' => $processed = $value->first() ?? [], + 'variables' => $processed = $value->first() ?? [], //@phpstan-ignore-line 'invoices' => $processed = (new HtmlEngine($value->first()->invitations()->first()))->setSettings($this->getSettings())->generateLabelsAndValues() ?? [], 'quotes' => $processed = (new HtmlEngine($value->first()->invitations()->first()))->setSettings($this->getSettings())->generateLabelsAndValues() ?? [], 'credits' => $processed = (new HtmlEngine($value->first()->invitations()->first()))->setSettings($this->getSettings())->generateLabelsAndValues() ?? [], - 'payments' => $processed = (new PaymentHtmlEngine($value->first(), $value->first()->client->contacts()->first()))->setSettings($this->getSettings())->generateLabelsAndValues() ?? [], + 'payments' => $processed = (new PaymentHtmlEngine($value->first(), $value->first()->client->contacts()->first()))->setSettings($this->getSettings())->generateLabelsAndValues() ?? [], //@phpstan-ignore-line 'tasks' => $processed = [], 'projects' => $processed = [], 'purchase_orders' => (new VendorHtmlEngine($value->first()->invitations()->first()))->setSettings($this->getSettings())->generateLabelsAndValues() ?? [], @@ -533,7 +533,7 @@ class TemplateService 'tax_rate3' => (float) $invoice->tax_rate3, 'total_taxes' => Number::formatMoney($invoice->total_taxes, $invoice->client), 'total_taxes_raw' => $invoice->total_taxes, - 'is_amount_discount' => (bool) $invoice->is_amount_discount ?? false, + 'is_amount_discount' => (bool) $invoice->is_amount_discount ?? false,//@phpstan-ignore-line 'footer' => $invoice->footer ?? '', 'partial' => $invoice->partial ?? 0, 'partial_due_date' => $this->translateDate($invoice->partial_due_date, $invoice->client->date_format(), $invoice->client->locale()), @@ -864,7 +864,7 @@ class TemplateService 'tax_rate3' => (float) $credit->tax_rate3, 'total_taxes' => Number::formatMoney($credit->total_taxes, $credit->client), 'total_taxes_raw' => $credit->total_taxes, - 'is_amount_discount' => (bool) $credit->is_amount_discount ?? false, + 'is_amount_discount' => (bool) $credit->is_amount_discount ?? false, //@phpstan-ignore-line 'footer' => $credit->footer ?? '', 'partial' => $credit->partial ?? 0, 'partial_due_date' => $this->translateDate($credit->partial_due_date, $credit->client->date_format(), $credit->client->locale()), @@ -1014,7 +1014,7 @@ class TemplateService 'custom_value4' => (string) $project->custom_value4 ?: '', 'color' => (string) $project->color ?: '', 'current_hours' => (int) $project->current_hours ?: 0, - 'tasks' => ($project->tasks && !$nested) ? $this->processTasks($project->tasks, true) : [], + 'tasks' => ($project->tasks && !$nested) ? $this->processTasks($project->tasks, true) : [], //@phpstan-ignore-line 'client' => $project->client ? [ 'name' => $project->client->present()->name(), 'balance' => $project->client->balance, diff --git a/app/Transformers/ProductTransformer.php b/app/Transformers/ProductTransformer.php index 181db94c0777..2310757f903a 100644 --- a/app/Transformers/ProductTransformer.php +++ b/app/Transformers/ProductTransformer.php @@ -74,7 +74,7 @@ class ProductTransformer extends EntityTransformer 'notes' => $product->notes ?: '', 'cost' => (float) $product->cost ?: 0, 'price' => (float) $product->price ?: 0, - 'quantity' => is_numeric($product->quantity) ? (float) $product->quantity : (float) 1.0, + 'quantity' => is_numeric($product->quantity) ? (float) $product->quantity : (float) 1.0, //@phpstan-ignore-line 'tax_name1' => $product->tax_name1 ?: '', 'tax_rate1' => (float) $product->tax_rate1 ?: 0, 'tax_name2' => $product->tax_name2 ?: '', diff --git a/app/Transformers/PurchaseOrderTransformer.php b/app/Transformers/PurchaseOrderTransformer.php index 4d1a2469beeb..d1aa872d1492 100644 --- a/app/Transformers/PurchaseOrderTransformer.php +++ b/app/Transformers/PurchaseOrderTransformer.php @@ -78,7 +78,7 @@ class PurchaseOrderTransformer extends EntityTransformer { $transformer = new VendorTransformer($this->serializer); - if (!$purchase_order->vendor) { + if (!$purchase_order->vendor) {//@phpstan-ignore-line return null; } diff --git a/app/Transformers/TaskTransformer.php b/app/Transformers/TaskTransformer.php index 668cc4f7f3aa..fc9df5f53386 100644 --- a/app/Transformers/TaskTransformer.php +++ b/app/Transformers/TaskTransformer.php @@ -67,7 +67,7 @@ class TaskTransformer extends EntityTransformer { $transformer = new UserTransformer($this->serializer); - if (!$task->user) { + if (!$task->user) { //@phpstan-ignore-line return null; } diff --git a/config/ninja.php b/config/ninja.php index 7a0377b39fc4..b8d1f187c242 100644 --- a/config/ninja.php +++ b/config/ninja.php @@ -17,8 +17,8 @@ return [ 'require_https' => env('REQUIRE_HTTPS', true), 'app_url' => rtrim(env('APP_URL', ''), '/'), 'app_domain' => env('APP_DOMAIN', 'invoicing.co'), - 'app_version' => env('APP_VERSION', '5.10.3'), - 'app_tag' => env('APP_TAG', '5.10.3'), + 'app_version' => env('APP_VERSION', '5.10.4'), + 'app_tag' => env('APP_TAG', '5.10.4'), 'minimum_client_version' => '5.0.16', 'terms_version' => '1.0.1', 'api_secret' => env('API_SECRET', false),