Page MenuHomePhabricator

D18240.diff
No OneTemporary

D18240.diff

diff --git a/src/view/form/control/AphrontFormTokenizerControl.php b/src/view/form/control/AphrontFormTokenizerControl.php
--- a/src/view/form/control/AphrontFormTokenizerControl.php
+++ b/src/view/form/control/AphrontFormTokenizerControl.php
@@ -33,6 +33,14 @@
return $this;
}
+ private function getPlaceholder() {
+ if (!strlen($this->placeholder)) {
+ $datasource = $this->datasource;
+ return $datasource->getPlaceholderText();
+ }
+ return $this->placeholder;
+ }
+
public function setInitialValue(array $initial_value) {
$this->initialValue = $initial_value;
return $this;
@@ -67,10 +75,7 @@
}
$datasource->setViewer($this->getUser());
- $placeholder = null;
- if (!strlen($this->placeholder)) {
- $placeholder = $datasource->getPlaceholderText();
- }
+ $placeholder = $this->getPlaceholder();
$values = nonempty($this->getValue(), array());
$tokens = $datasource->renderTokens($values);

File Metadata

Mime Type
text/plain
Expires
May 9 2024, 7:46 AM (5 w, 4 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6274409
Default Alt Text
D18240.diff (980 B)

Event Timeline