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
F14822363: D18677.id44843.diff
Tue, Jan 28, 7:58 AM
Unknown Object (File)
Mon, Jan 27, 7:47 AM
Unknown Object (File)
Sat, Jan 25, 2:21 PM
Unknown Object (File)
Wed, Jan 22, 3:36 PM
Unknown Object (File)
Tue, Jan 21, 9:56 AM
Unknown Object (File)
Sun, Jan 19, 10:20 AM
Unknown Object (File)
Thu, Jan 16, 10:41 AM
Unknown Object (File)
Thu, Jan 9, 9:18 PM
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