Refactor the way of symbols was handled, now compatible with "monks enhanced journal".
This commit is contained in:
@@ -46,26 +46,13 @@ export class BaseJournalSheetL5r5e extends JournalSheet {
|
||||
* @override
|
||||
*/
|
||||
activateEditor(name, options = {}, initialContent = "") {
|
||||
// For Compatibility with old compendium modules (PRE l5r v1.7.2)
|
||||
if (initialContent) {
|
||||
initialContent = game.l5r5e.HelpersL5r5e.convertSymbols(initialContent, false);
|
||||
}
|
||||
super.activateEditor(name, options, initialContent);
|
||||
}
|
||||
|
||||
/**
|
||||
* This method is called upon form submission after form data is validated
|
||||
* @param event {Event} The initial triggering submission event
|
||||
* @param formData {Object} The object of validated form data with which to update the object
|
||||
* @returns {Promise} A Promise which resolves once the update operation has completed
|
||||
* @override
|
||||
*/
|
||||
async _updateObject(event, formData) {
|
||||
if (formData.content) {
|
||||
formData.content = game.l5r5e.HelpersL5r5e.convertSymbols(formData.content, true);
|
||||
}
|
||||
return super._updateObject(event, formData);
|
||||
}
|
||||
|
||||
/**
|
||||
* Subscribe to events from the sheet.
|
||||
* @param {jQuery} html HTML content of the sheet.
|
||||
|
||||
Reference in New Issue
Block a user