From: Mikael Nordfeldth Date: Fri, 4 Sep 2015 18:35:11 +0000 (+0200) Subject: Incorrect use of DataObject type matching after ->find() X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=1e07f8c045decda6a1d71f5551dd1357a5af0bc3;p=quix0rs-gnu-social.git Incorrect use of DataObject type matching after ->find() --- diff --git a/classes/Conversation.php b/classes/Conversation.php index 537c214a4c..9ef1e06b76 100644 --- a/classes/Conversation.php +++ b/classes/Conversation.php @@ -110,8 +110,7 @@ class Conversation extends Managed_DataObject { $conv = new Conversation(); $conv->id = $notice->conversation; - $conv->find(true); - if (!$conv instanceof Conversation) { + if (!$conv->find(true)) { common_debug('Conversation does not exist for notice ID: '.$notice->id); throw new NoResultException($conv); }