Skip to content
GitLab
    • Why GitLab
    • Pricing
    • Contact Sales
    • Explore
  • Why GitLab
  • Pricing
  • Contact Sales
  • Explore
  • Sign in
  • Get free trial
  • foundryvtt_pf1
  • foundryvtt-pathfinder1
  • Issues
  • #1902

getDefaultChargeFormula() can error with spellpoints enabled

TypeError: Cannot read properties of undefined (reading 'cost')
    at ItemSpellPF.getDefaultChargeFormula (item-spell.mjs:209:38)
    at ItemSpellPF.getDefaultChargeCost (item-spell.mjs:200:28)

Caused by the line:

      return this.system.spellPoints.cost || "0";

Which is because the system allows system.spellPoints to not exist, which is fine, it's just missing ? in the data path.

Assignee
Assign to
Time tracking