Port the changes from contao/core@fb3e554149547530c6bc62b80b13c502cdb7f88c