Skip to content

Coerce strings that look like bools or numbers into booleans or numbers when applying unguided AEs - #7258

Open
krbz999 wants to merge 1 commit into
foundryvtt:6.0.xfrom
krbz999:coerce-bool-or-number-like-effect-values-when-unguided
Open

Coerce strings that look like bools or numbers into booleans or numbers when applying unguided AEs#7258
krbz999 wants to merge 1 commit into
foundryvtt:6.0.xfrom
krbz999:coerce-bool-or-number-like-effect-values-when-unguided

Conversation

@krbz999

@krbz999 krbz999 commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Currently, using flags.world.foo | override | true results in Actor#flags.world.foo === "true" and similar applies when using numeric-like values.

This changes it such that if the change is unguided (not targeting a datafield) but target flags, it is attempted to be coerced into a boolean or number.

This helps with the new conditionals as currently something like this is not possible:

flags.world.foo | Override | true

and a different change with

k: "flags.world.foo",
o: "exact",
v: true

(Note: in conjunction with #7257)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api feature request priority: low strategic Requires sign-off from a core Foundry VTT developer before merge. system: active effects

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants