Page MenuHomePhabricator

Fix incorrect construction of subtype map when validating "subtype" transactions against non-subtypable objects
ClosedPublic

Authored by epriestley on Aug 27 2019, 2:57 PM.
Tags
None
Referenced Files
F19039576: D20741.diff
Nov 26 2025, 8:26 AM
F18988695: D20741.diff
Nov 18 2025, 7:14 AM
F18838590: D20741.id.diff
Oct 27 2025, 11:37 AM
F18830805: D20741.diff
Oct 25 2025, 8:57 AM
F18761391: D20741.id49454.diff
Oct 6 2025, 2:02 PM
F18759890: D20741.diff
Oct 6 2025, 6:32 AM
F18754901: D20741.id.diff
Oct 5 2025, 2:19 AM
F18570542: D20741.id49457.diff
Sep 10 2025, 3:54 AM
Subscribers
None

Details

Summary

Fixes T13389. Currently, we try to "newSubtypeMap()" unconditionally, even if the underlying object does not support subtypes.

  • Only try to build a subtype map if subtype transactions are actually being applied.
  • When subtype transactions are applied to a non-subtypable object, fail more explicitly.
Test Plan

Clicked "Make Editable" in a fresh Calendar transaction form, got an editable form instead of a fatal from "newSubtypeMap()". (Calendar events are not currently subtypable.)

Diff Detail

Repository
rP Phabricator
Branch
subtype1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 23312
Build 32030: Run Core Tests
Build 32029: arc lint + arc unit

Event Timeline

This revision was not accepted when it landed; it landed in state Needs Review.Aug 28 2019, 1:57 PM
This revision was automatically updated to reflect the committed changes.