Page MenuHomePhabricator

Add a missing "null" check when rebuilding old/new diff content
ClosedPublic

Authored by epriestley on Apr 25 2020, 4:21 PM.
Tags
None
Referenced Files
F15465347: D21169.id50404.diff
Wed, Apr 2, 5:40 PM
F15465052: D21169.id50405.diff
Wed, Apr 2, 2:02 PM
F15463003: D21169.id.diff
Tue, Apr 1, 7:42 PM
F15460317: D21169.diff
Mon, Mar 31, 9:57 PM
F15409039: D21169.id50405.diff
Mar 19 2025, 3:00 AM
F15360650: D21169.diff
Mar 11 2025, 9:25 AM
F15315965: D21169.id50404.diff
Mar 6 2025, 6:17 PM
F15315959: D21169.id.diff
Mar 6 2025, 6:17 PM
Subscribers
None

Details

Summary

See https://discourse.phabricator-community.org/t/exceptions-when-viewing-diffs/3787. This list may include null values.

Until PHP 7.4, $x = null; echo $x['y']; does not emit a warning. Sneaky!

Test Plan
  • Traced null values from reparseHunksForSpecialAttributes(), saw them no longer incorporated into corpus bodies.
  • This has some amount of test coverage.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision was not accepted when it landed; it landed in state Needs Review.Apr 25 2020, 4:22 PM
epriestley requested review of this revision.
This revision was automatically updated to reflect the committed changes.