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
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
Unknown Object (File)
Jan 27 2025, 7:47 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
Branch
editable1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 18623
Build 25087: Run Core Tests
Build 25086: arc lint + arc unit