Normally discard draft expects the page to revert to the exact state it was when you last published it. However what happens in the case that the user did not set the mapping type, but you set it after? It becomes impossible to truly revert back since you cannot revert the mapping type currently in display page templates. This can be very problematic if you accidently choose the wrong mapping type.
Steps to Reproduce
- Create a Display page templates with some fragments
- Change mapping type
- Discard Draft
Mapping type returned to normal
Tested on Tomcat 9.0.17 + MySQL 5.7
Portal master GIT ID: cd778159969289540f3e8a2793c83b2824f00ef2