Skip to content

Commit

Permalink
Explicitly set the legacy template in the TwoFactorController (see #5870
Browse files Browse the repository at this point in the history
)

Description
-----------

Fixes #5859

The two factor controller is the only fragment controller that does not have a modern template, yet. 🙈 Unfortunately, we cannot really introduce one now without breaking cases where people adjusted the legacy template (this won't work anymore then). The downside is, that we will only be able to move away from this in Contao 6. But as modules should be phased out anyways in the distant future, this might not be such a big problem…

This PR fixes the issue by manually defining the legacy template (`mod_two_factor`) in the controller, effectively overwriting the new default (`frontend_module/two_factor`).

@Kabathus Can you check if this fixes your issue?

Commits
-------

dcb3b55 explicitly set the legacy template
  • Loading branch information
m-vo committed Mar 13, 2023
1 parent a90c3ab commit 9b64119
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
/**
* @internal
*/
#[AsFrontendModule(category: 'user')]
#[AsFrontendModule(category: 'user', template: 'mod_two_factor')]
class TwoFactorController extends AbstractFrontendModuleController
{
protected PageModel|null $pageModel = null;
Expand Down

0 comments on commit 9b64119

Please sign in to comment.