From: cash Date: Sat, 18 Jun 2011 19:57:37 +0000 (-0400) Subject: using elgg_delete_river() rather than custom SQL in blog save action X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=c4ae03d15a001145321dbba67121454a6dc80aa3;p=lorea%2Felgg.git using elgg_delete_river() rather than custom SQL in blog save action --- diff --git a/mod/blog/actions/blog/save.php b/mod/blog/actions/blog/save.php index c42845037..0720d6163 100644 --- a/mod/blog/actions/blog/save.php +++ b/mod/blog/actions/blog/save.php @@ -148,9 +148,10 @@ if (!$error) { $blog->save(); } } elseif ($old_status == 'published' && $status == 'draft') { - $q = "DELETE FROM {$db_prefix}river - WHERE object_guid = $blog->guid AND action_type = 'create'"; - delete_data($q); + elgg_delete_river(array( + 'object_guid' => $blog->guid, + 'action_type' => 'create', + )); } if ($blog->status == 'published') {