From 9f6ac44278cdb935e9807a8b694c2786ada50d92 Mon Sep 17 00:00:00 2001
From: Armin Felder <armin.felder@osalliance.com>
Date: Mon, 6 Aug 2018 01:36:24 +0200
Subject: [PATCH] ifixed custom emojies

---
 api/meteorddp.cpp    | 4 ++++
 rocketchatserver.cpp | 2 +-
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/api/meteorddp.cpp b/api/meteorddp.cpp
index eb6668f..56c8f7e 100755
--- a/api/meteorddp.cpp
+++ b/api/meteorddp.cpp
@@ -48,6 +48,10 @@ void MeteorDDP::init( const QString &pUri )
     connect( mWsClient, &Websocket::connected, this, &MeteorDDP::onConnected, Qt::UniqueConnection );
     connect( mWsClient, &Websocket::closed, this, &MeteorDDP::ddpDisconnected );
     connect( this, &MeteorDDP::sendMessageSignal, this, &MeteorDDP::sendJson, Qt::UniqueConnection );
+    connect( mWsClient, &Websocket::error, this, [ = ]( QString error ) {
+        qDebug() << "test";
+        qDebug() << error;
+    } );
     mWsClient->open( wsUri );
     QDateTime now = QDateTime::currentDateTime();
     uint currentTime = now.toTime_t();
diff --git a/rocketchatserver.cpp b/rocketchatserver.cpp
index f1d5063..2372d8a 100755
--- a/rocketchatserver.cpp
+++ b/rocketchatserver.cpp
@@ -1656,7 +1656,7 @@ void RocketChatServerData::getCustomEmojis()
     std::function<void ( QList<QSharedPointer<Emoji>> )> success = [ = ]( QList<QSharedPointer<Emoji>> pEmojiList ) {
         QVariantList variantList;
 
-        if ( variantList.size() ) {
+        if ( pEmojiList.size() ) {
             mStorage->transaction();
 
             for ( const auto &emoji : pEmojiList ) {
-- 
GitLab