Skip to content
Code-Schnipsel Gruppen Projekte
Commit d4b3d4e5 erstellt von Henning Leutz's avatar Henning Leutz :martial_arts_uniform:
Dateien durchsuchen

refactor: return hints

Übergeordneter c67a1649
No related branches found
No related tags found
Keine zugehörigen Merge Requests gefunden
......@@ -34,7 +34,7 @@ class EventHandling
*
* @return Handler
*/
protected static function getHandler()
protected static function getHandler(): ?Handler
{
if (self::$Handler === null) {
self::$Handler = new Handler();
......@@ -49,7 +49,7 @@ protected static function getHandler()
* @param QUI\Interfaces\Users\User $User
* @return array
*/
protected static function getUserDiscounts(QUI\Interfaces\Users\User $User)
protected static function getUserDiscounts(QUI\Interfaces\Users\User $User): array
{
if (isset(self::$userDiscounts[$User->getId()])) {
return self::$userDiscounts[$User->getId()];
......@@ -65,10 +65,10 @@ protected static function getUserDiscounts(QUI\Interfaces\Users\User $User)
* - Einkaufsmengeprüfung
*
* @param Discount $Discount
* @param integer|double|float $quantity
* @param integer|double $quantity
* @return bool
*/
public static function isDiscountUsableWithQuantity(Discount $Discount, $quantity)
public static function isDiscountUsableWithQuantity(Discount $Discount, $quantity): bool
{
$purchaseQuantityFrom = $Discount->getAttribute('purchase_quantity_from');
$purchaseQuantityUntil = $Discount->getAttribute('purchase_quantity_until');
......@@ -97,10 +97,10 @@ public static function isDiscountUsableWithQuantity(Discount $Discount, $quantit
* - Einkaufswertprüfung
*
* @param Discount $Discount
* @param integer|double|float $value
* @param integer|double $value
* @return bool
*/
public static function isDiscountUsableWithPurchaseValue(Discount $Discount, $value)
public static function isDiscountUsableWithPurchaseValue(Discount $Discount, $value): bool
{
$purchaseValueFrom = $Discount->getAttribute('purchase_value_from');
$purchaseValueUntil = $Discount->getAttribute('purchase_value_until');
......@@ -208,7 +208,7 @@ public static function onQuiqqerProductsCalcListProduct(
*
* @param Calc $Calc
* @param ProductList $List
* @param integer|double|float $nettoSum
* @param integer|double $nettoSum
*/
public static function onQuiqqerProductsCalcList(
Calc $Calc,
......
0% oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren