/** * @brief Get the last message sent * * @param string $to * @return void */ function ajaxLast($to) { $md = new \Modl\MessageDAO(); $m = $md->getLastItem($to); if (!isset($m->sticker)) { RPC::call('Chat.setTextarea', $m->body); } }