Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15393032
D15451.id37240.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D15451.id37240.diff
View Options
diff --git a/src/applications/herald/engine/HeraldEngine.php b/src/applications/herald/engine/HeraldEngine.php
--- a/src/applications/herald/engine/HeraldEngine.php
+++ b/src/applications/herald/engine/HeraldEngine.php
@@ -274,7 +274,7 @@
} else {
foreach ($conditions as $condition) {
try {
- $object->getHeraldField($condition->getFieldName());
+ $this->getConditionObjectValue($condition, $object);
} catch (Exception $ex) {
$reason = pht(
'Field "%s" does not exist!',
@@ -366,14 +366,11 @@
}
public function getObjectFieldValue($field) {
- if (isset($this->fieldCache[$field])) {
- return $this->fieldCache[$field];
+ if (!array_key_exists($field, $this->fieldCache)) {
+ $this->fieldCache[$field] = $this->object->getHeraldField($field);
}
- $result = $this->object->getHeraldField($field);
-
- $this->fieldCache[$field] = $result;
- return $result;
+ return $this->fieldCache[$field];
}
protected function getRuleEffects(
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mar 16 2025, 7:02 PM (4 w, 5 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7674110
Default Alt Text
D15451.id37240.diff (1 KB)
Attached To
Mode
D15451: Fix an issue with the Herald engine field value cache
Attached
Detach File
Event Timeline
Log In to Comment