BUG 000 Add hook for dashlets

This commit is contained in:
Julio Cesar Laura
2012-01-03 18:31:15 -04:00
parent d142665842
commit c003597d1b
11 changed files with 168 additions and 299 deletions

View File

@@ -19,7 +19,12 @@ class Dashlet extends BaseDashlet {
public function load($dasUid) {
try {
$dashlet = DashletPeer::retrieveByPK($dasUid);
return $dashlet->toArray(BasePeer::TYPE_FIELDNAME);
if (!is_null($dashlet)) {
return $dashlet->toArray(BasePeer::TYPE_FIELDNAME);
}
else {
return null;
}
}
catch (Exception $error) {
throw $error;