Page MenuHomePhabricator

Fix a fatal on user email settings when `account.editable` is disabled
ClosedPublic

Authored by epriestley on Oct 4 2017, 2:18 PM.
Tags
None
Referenced Files
F15467237: D18677.id44841.diff
Thu, Apr 3, 1:50 PM
Unknown Object (File)
Feb 14 2025, 1:00 AM
Unknown Object (File)
Feb 9 2025, 2:58 AM
Unknown Object (File)
Feb 8 2025, 2:35 AM
Unknown Object (File)
Feb 4 2025, 3:22 AM
Unknown Object (File)
Feb 1 2025, 2:27 PM
Unknown Object (File)
Jan 29 2025, 8:20 AM
Unknown Object (File)
Jan 28 2025, 7:58 AM
Subscribers
None

Details

Summary

If account.editable is set to false, we try to add a null button and fatal:

Argument 1 passed to PHUIHeaderView::addActionLink() must be an instance of PHUIButtonView, null given, called in /srv/phabricator/phabricator/src/applications/settings/panel/PhabricatorSettingsPanel.php on line 290

Instead, don't try to render null as a button.

Test Plan
  • Configured account.editable false.
  • Viewed email address settings.
  • Before: fatal.
  • After: page works, no button is provided.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable