Skip to content

[BUG] TYPO3 exception when calling ProductController::addAction() #646

@terminal8-af

Description

@terminal8-af

Bug Report

Current Behavior
When adding a Product (from the cart_products extension) to the cart, a TYPO3 exception is thrown.

TYPO3\CMS\Extbase\Mvc\Controller\ActionController::addFlashMessage(): Argument #3 ($severity) 
must be of type TYPO3\CMS\Core\Type\ContextualFeedbackSeverity, int given, called in 
/typo3conf/ext/cart/Classes/Controller/Cart/ProductController.php on line 125

Expected behavior/output
Adding a product to the cart should not throw a TYPO3 exception.

Environment

  • TYPO3 version: 13.4.7
  • cart version: 11.3.0
  • Is your TYPO3 installation set up with Composer (Composer Mode): no

Possible Solution
Change line 54 in Classes/Controller/Cart/PorductController.php from $severity = ContextualFeedbackSeverity::OK->value; to $severity = ContextualFeedbackSeverity::OK;

Metadata

Metadata

Assignees

Labels

11.xrelated to TYPO3 v13

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions