Commit 58fd6891 authored by louiz’'s avatar louiz’

Add a ifndef USE_DATABASE guard around send_history_message

parent cb831788
......@@ -4,7 +4,6 @@
#include <logger/logger.hpp>
#include <xmpp/xmpp_component.hpp>
#include <database/database.hpp>
#include <config/config.hpp>
#include <utils/system.hpp>
#include <utils/time.hpp>
......@@ -399,6 +398,7 @@ void XmppComponent::send_muc_message(const std::string& muc_name, const std::str
this->send_stanza(message);
}
#ifdef USE_DATABASE
void XmppComponent::send_history_message(const std::string& muc_name, const std::string& nick, const std::string& body_txt, const std::string& jid_to, Database::time_point::rep timestamp)
{
Stanza message("message");
......@@ -422,6 +422,7 @@ void XmppComponent::send_history_message(const std::string& muc_name, const std:
this->send_stanza(message);
}
#endif
void XmppComponent::send_muc_leave(const std::string& muc_name, const std::string& nick, Xmpp::body&& message,
const std::string& jid_to, const bool self, const bool user_requested)
......
#pragma once
#include "biboumi.h"
#include <xmpp/adhoc_commands_handler.hpp>
#include <network/tcp_client_socket_handler.hpp>
#include <database/database.hpp>
#include <xmpp/xmpp_parser.hpp>
#include <xmpp/body.hpp>
......@@ -133,11 +135,13 @@ public:
*/
void send_muc_message(const std::string& muc_name, const std::string& nick, Xmpp::body&& body, const std::string& jid_to,
std::string uuid);
#ifdef USE_DATABASE
/**
* Send a message, with a <delay/> element, part of a MUC history
*/
void send_history_message(const std::string& muc_name, const std::string& nick, const std::string& body,
const std::string& jid_to, const std::time_t timestamp);
#endif
/**
* Send an unavailable presence for this nick
*/
......
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