objTable->getRow($where); if (!$msg) { throw new Exception('message not found', CODE_NORMAL_ERROR); } if ($msg['from'] != $from) { throw new Exception('no permission', CODE_NO_PERMITION); } if ((time() - strtotime($msg['create_time']) > self::MAX_REPEAL_TIME)) { throw new Exception('repeal message time out', CODE_NORMAL_ERROR); } $this->objTable->updateObject(['state' => 0], $where); ThirdApi::pushPersonEvent($msg['to'], [ 'type' => 'repeal', 'from' => $from, 'to' => $msg['to'], 'hash' => $hash, ]); return true; } }