- Переписан метод определения прочитанности сообщения

parent 51d28728
......@@ -147,8 +147,8 @@ class UnisenderAPI {
* @return bool
*/
public function isReaded(){
if (array_key_exists('result', $this->statuses) && array_key_exists('data', $this->statuses['result'])) {
if ($this->statuses['result']['status']==ConditionBase::MESSAGE_READ || $this->statuses['result']['status']==ConditionBase::MESSAGE_UNSUBSCRIBED || $this->statuses['result']['status']==ConditionBase::MESSAGE_SPAM_FOLDER)
foreach($this->statuses as $status) {
if ($status==ConditionBase::MESSAGE_READ || $status==ConditionBase::MESSAGE_SPAM_FOLDER || $status==ConditionBase::MESSAGE_UNSUBSCRIBED)
return true;
}
return false;
......
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