Working on Compatibility for FVTT v10
Updated compendium for content-link (added an uuid) Journal activateListeners -> _activatePageListeners
This commit is contained in:
@@ -313,12 +313,12 @@ export class TwentyQuestions {
|
||||
const newItemsData = [];
|
||||
Object.values(itemsCache).forEach((types) => {
|
||||
types.forEach((item) => {
|
||||
const itemData = foundry.utils.duplicate(item.data);
|
||||
if (itemData.data?.bought_at_rank) {
|
||||
itemData.data.bought_at_rank = 0;
|
||||
const itemData = foundry.utils.duplicate(item);
|
||||
if (itemData.system?.bought_at_rank) {
|
||||
itemData.system.bought_at_rank = 0;
|
||||
}
|
||||
if (itemData.data?.xp_spent) {
|
||||
itemData.data.xp_spent = 0;
|
||||
if (itemData.system?.xp_spent) {
|
||||
itemData.system.xp_spent = 0;
|
||||
}
|
||||
newItemsData.push(itemData);
|
||||
});
|
||||
|
||||
@@ -54,11 +54,12 @@ export class BaseJournalSheetL5r5e extends JournalSheet {
|
||||
}
|
||||
|
||||
/**
|
||||
* Subscribe to events from the sheet.
|
||||
* @param {jQuery} html HTML content of the sheet.
|
||||
* Activate listeners after page content has been injected.
|
||||
* @protected
|
||||
*/
|
||||
activateListeners(html) {
|
||||
super.activateListeners(html);
|
||||
_activatePageListeners() {
|
||||
super._activatePageListeners();
|
||||
const html = this.element;
|
||||
|
||||
// Commons
|
||||
game.l5r5e.HelpersL5r5e.commonListeners(html);
|
||||
|
||||
Reference in New Issue
Block a user