Skip to content
Code-Schnipsel Gruppen Projekte

fix(phpstan): code improvements and resolve warnings

Zusammengeführt Henning Leutz schlägt vor, next-2.x in main zu mergen.
  1. Feb 27, 2025
  2. Feb 23, 2025
    • Henning Leutz's avatar
      chore(phpstan): update gitlab-ci configuration · 782f0cd0
      verfasst von Henning Leutz
      Debug test
      782f0cd0
    • Henning Leutz's avatar
      chore: phpstan modify · 0c2d3abe
      verfasst von Henning Leutz
      In this commit, modifications have been made to the .gitlab-ci.yml file to allow running PHPUnit on
      PHP 8.3 in our pipeline. A new job `modify-job` was added which runs phpstan script with following
      instructions:
      
      - Keeping other autoloaders with `QUIQQER_OTHER_AUTOLOADERS=KEEP`
      - Disabling progress display with `--no-progress`
      - Removing memory limit with `--memory-limit=-1`
      - Enabling debug mode with `--debug`
      0c2d3abe
  3. Feb 22, 2025
    • Henning Leutz's avatar
      chore: update phpstan configuration file · 2ab12e56
      verfasst von Henning Leutz
      The commit modifies the phpstan.dist.neon configuration file. The changes include removing the
      excludePaths section and adjusting the end of the file to not have a new line. This simplification
      will better suit our testing environment.
      2ab12e56
    • Henning Leutz's avatar
      fix: update phpstan config and add condition to package setup in src/QUI/ERP/Coupons/Events.php · 749db82c
      verfasst von Henning Leutz
      This commit includes a minor modification in the `phpstan.dist.neon` file where the `excludePaths`
      value has been updated. Besides, a conditional check has been added in the `onPackageSetup`
      function, under `Events.php` in the `src/QUI/ERP/Coupons` directory, to only proceed if the package
      name is 'quiqqer/coupons'. This additional check generally improves the efficiency and correctness
      of the package setup process.
      749db82c
    • Henning Leutz's avatar
      chore(phpstan): exclude problematic file from phpstan analysis · 7e2e2aea
      verfasst von Henning Leutz
      This commit modifies the phpstan.dist.neon to exclude the DigitalCouponProductType.php file from
      being analyzed by PHPStan. This was necessary due to consistent unresolvable errors.
      7e2e2aea
    • Henning Leutz's avatar
      refactor(phpstand): update coupon code and physical coupon product · 6ca95f6b
      verfasst von Henning Leutz
      This commit modifies the `src/QUI/ERP/Coupons/CouponCode.php` by removing an unexplained variable
      annotation.
      In `src/QUI/ERP/Coupons/Products/PhysicalCouponProductType.php`, it introduces an import statement
      for `QUI\\Locale` and updated the `Locale` parameter type definition in `getTypeDescription`
      function. This change improves code readability and consistency.
      6ca95f6b
    • Henning Leutz's avatar
      fix(phpstan): code improvements and resolve warnings · 2833ed98
      verfasst von Henning Leutz
      Reviewed code and made several improvements which provide better error handling, code quality, and
      resolved warnings. The changes include:
      - Syntax modifications for better readability,
      - Ensured variable type checks before using methods,
      - Resolved warning instances in phpstan,
      - Adapted code to comply with modern PHP nullable type indicator.
      
      Alongside, made version update in phive/phars.xml. Also, unnecessary comments or instances are
      removed for a cleaner code.
      
      Related: #16
      2833ed98