Use the Item class instead of DBA calls when possible

This commit is contained in:
Michael 2018-08-15 04:41:49 +00:00
commit e8334c4655
5 changed files with 23 additions and 21 deletions

View file

@ -152,7 +152,7 @@ function item_post(App $a) {
// Check for multiple posts with the same message id (when the post was created via API)
if (($message_id != '') && ($profile_uid != 0)) {
if (DBA::exists('item', ['uri' => $message_id, 'uid' => $profile_uid])) {
if (Item::exists(['uri' => $message_id, 'uid' => $profile_uid])) {
logger("Message with URI ".$message_id." already exists for user ".$profile_uid, LOGGER_DEBUG);
return;
}