We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit 1104ea2a authored by mattl's avatar mattl

Fave insert logging directly in insert()

parent e41d324a
......@@ -63,12 +63,9 @@ class Fave extends Managed_DataObject
try {
} catch (ServerException $e) {
common_log_db_error($fave, 'INSERT', __FILE__);
throw $e;
// throws exception (Fave specific until migrated into Managed_DataObject
......@@ -82,7 +79,8 @@ class Fave extends Managed_DataObject
// exception throwing takeover!
public function insert()
if (!parent::insert()) {
if (parent::insert()===false) {
common_log_db_error($this, 'INSERT', __FILE__);
throw new ServerException(sprintf(_m('Could not store new object of type %s'), get_called_class()));
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment