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
Unknown Object (File)
Thu, Apr 11, 8:50 AM
Unknown Object (File)
Sat, Apr 6, 8:09 AM
Unknown Object (File)
Thu, Apr 4, 8:52 AM
Unknown Object (File)
Sun, Mar 31, 11:33 AM
Unknown Object (File)
Sun, Mar 31, 11:32 AM
Unknown Object (File)
Sun, Mar 31, 11:32 AM
Unknown Object (File)
Mar 20 2024, 2:44 AM
Unknown Object (File)
Mar 5 2024, 10:28 AM
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.