Differential D25132 Diff 537 src/applications/home/menuitem/PhabricatorHomeLauncherProfileMenuItem.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/home/menuitem/PhabricatorHomeLauncherProfileMenuItem.php
Show All 25 Lines | public function canMakeDefault( | ||||
PhabricatorProfileMenuItemConfiguration $config) { | PhabricatorProfileMenuItemConfiguration $config) { | ||||
return false; | return false; | ||||
} | } | ||||
public function getDisplayName( | public function getDisplayName( | ||||
PhabricatorProfileMenuItemConfiguration $config) { | PhabricatorProfileMenuItemConfiguration $config) { | ||||
$name = $config->getMenuItemProperty('name'); | $name = $config->getMenuItemProperty('name'); | ||||
if (strlen($name)) { | if (phutil_nonempty_string($name)) { | ||||
valerio.bozzolan: ✅ OK since the expected input domain is **NULL** (default) or a **string**. The phutil will… | |||||
return $name; | return $name; | ||||
} | } | ||||
return $this->getDefaultName(); | return $this->getDefaultName(); | ||||
} | } | ||||
public function buildEditEngineFields( | public function buildEditEngineFields( | ||||
PhabricatorProfileMenuItemConfiguration $config) { | PhabricatorProfileMenuItemConfiguration $config) { | ||||
Show All 28 Lines |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0
✅ OK since the expected input domain is NULL (default) or a string. The phutil will throw for alien types, and it's OK.
Context input: