Longman\TelegramBot\Conversation::updateStatus PHP Method

updateStatus() protected method

Update the status of the current conversation
protected updateStatus ( string $status ) : boolean
$status string
return boolean
    protected function updateStatus($status)
    {
        if ($this->exists()) {
            $fields = ['status' => $status];
            $where = ['id' => $this->conversation['id'], 'status' => 'active', 'user_id' => $this->user_id, 'chat_id' => $this->chat_id];
            if (ConversationDB::updateConversation($fields, $where)) {
                return true;
            }
        }
        return false;
    }