Skip to content

Commit

Permalink
fix phpstan (#30231)
Browse files Browse the repository at this point in the history
* fix phpstan

* Update product.class.php

* Update product.class.php
  • Loading branch information
frederic34 authored Jul 1, 2024
1 parent f7c0253 commit 4cb64b5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion htdocs/product/class/product.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -2380,7 +2380,7 @@ public function updatePrice($newprice, $newpricebase, $user, $newvat = null, $ne
return -1;
}

if ($newprice !== '' || $newprice === 0) {
if ($newprice === 0 || $newprice !== '') {
if ($newpricebase == 'TTC') {
$price_ttc = price2num($newprice, 'MU');
$price = (float) price2num($newprice) / (1 + ((float) $newvat / 100));
Expand Down
11 changes: 6 additions & 5 deletions htdocs/stripe/class/actions_stripe.class.php
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
<?php
/* Copyright (C) 2009-2016 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2011 Herve Prot <herve.prot@symeos.com>
* Copyright (C) 2014 Philippe Grand <philippe.grand@atoo-net.com>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
/* Copyright (C) 2009-2016 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2011 Herve Prot <herve.prot@symeos.com>
* Copyright (C) 2014 Philippe Grand <philippe.grand@atoo-net.com>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -41,7 +42,7 @@ class ActionsStripeconnect extends CommonHookActions
*/
public $db;

private $config = array();
private $config = array(); // @phpstan-ignore-line


/**
Expand Down

0 comments on commit 4cb64b5

Please sign in to comment.