diff --git a/src/module/actor/base.ts b/src/module/actor/base.ts index fcf08ed4898..53927c25cd7 100644 --- a/src/module/actor/base.ts +++ b/src/module/actor/base.ts @@ -2066,9 +2066,10 @@ const ActorProxyPF2e = new Proxy(ActorPF2e, { args: [source: PreCreate, context?: DocumentConstructionContext], ) { const type = args[0]?.type; - const ActorClass = CONFIG.PF2E.Actor.documentClasses[type]; + const ActorClass: typeof ActorPF2e = + (type as string | undefined) === "base" ? ActorPF2e : CONFIG.PF2E.Actor.documentClasses[type]; if (!ActorClass) { - throw ErrorPF2e(`Actor type ${type} does not exist and actor module sub-types are not supported`); + throw ErrorPF2e(`Actor type ${type} does not exist, and actor module subtypes are not supported`); } return new ActorClass(...args); }, diff --git a/src/module/item/base/document.ts b/src/module/item/base/document.ts index 08d12c9bbfa..735c7b16b45 100644 --- a/src/module/item/base/document.ts +++ b/src/module/item/base/document.ts @@ -1027,9 +1027,10 @@ const ItemProxyPF2e = new Proxy(ItemPF2e, { : source?.type === "consumable" && (source.system?.category as string | undefined) === "ammo" ? "ammo" : source?.type; - const ItemClass: typeof ItemPF2e = CONFIG.PF2E.Item.documentClasses[type]; + const ItemClass: typeof ItemPF2e = + (source?.type as string | undefined) === "base" ? ItemPF2e : CONFIG.PF2E.Item.documentClasses[type]; if (!ItemClass) { - throw ErrorPF2e(`Item type ${type} does not exist and item module sub-types are not supported`); + throw ErrorPF2e(`Item type ${type} does not exist, and item module subtypes are not supported`); } return new ItemClass(...args); },