Project

General

Profile

Actions

Bug #92249

closed

js: BackendException is invoked incorrectly in TYPO3/CMS/Backend/FormEngine

Added by Benjamin Franzke about 4 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Backend JavaScript
Start date:
2020-09-09
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
11
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

The BackendException class is exported as named (not as default) [1]
export in BackendException.ts, and therefore the module consumer
needs to access the BackendException property of the module.

Once a interactionRequest is missing in the FormEngine cosume() method [2],
the following javascript errors occurs:

FormEngine.js?bust=xxxxxxxxxxxxx:386 Uncaught TypeError: BackendException is not a constructor

[1] https://github.com/TYPO3/TYPO3.CMS/blob/e1ab7023e3ae4c9b1d6674a0974037ccced3841e/Build/Sources/TypeScript/backend/Resources/Public/TypeScript/BackendException.ts#L14
[2] https://github.com/TYPO3/TYPO3.CMS/blob/e1ab7023e3ae4c9b1d6674a0974037ccced3841e/typo3/sysext/backend/Resources/Public/JavaScript/FormEngine.js#L387

Note: I don't know how to trigger this, but by unconditially throwing the BackendException exception reveals that the current code is wrong.

Actions

Also available in: Atom PDF