Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F1102532
D167.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Aug 19, 4:27 AM
Size
757 B
Mime Type
text/x-diff
Expires
Wed, Aug 20, 4:27 AM (14 h, 13 m)
Engine
blob
Format
Raw Data
Handle
714217
Attached To
D167: INP-1514 Reset validation errors before object loading
D167.diff
View Options
Index: branches/5.2.x/core/kernel/db/dbitem.php
===================================================================
--- branches/5.2.x/core/kernel/db/dbitem.php
+++ branches/5.2.x/core/kernel/db/dbitem.php
@@ -401,6 +401,8 @@
*/
public function Load($id, $id_field_name = null, $cachable = false)
{
+ $this->Clear();
+
if ( isset($id_field_name) ) {
$this->IDField = $id_field_name; // set new IDField
}
@@ -420,7 +422,7 @@
}
if (($id === false) || !$keys_sql) {
- return $this->Clear();
+ return false;
}
if (!$this->raiseEvent('OnBeforeItemLoad', $id)) {
@@ -453,7 +455,7 @@
$this->Loaded = true;
}
else {
- return $this->Clear();
+ return false;
}
if (is_array($id) || isset($id_field_name)) {
Event Timeline
Log In to Comment