Remove unused functions for getting crypto keys
This commit is contained in:
@@ -20,7 +20,6 @@
|
|||||||
#include <Quotient/csapi/profile.h>
|
#include <Quotient/csapi/profile.h>
|
||||||
#include <Quotient/csapi/registration.h>
|
#include <Quotient/csapi/registration.h>
|
||||||
#include <Quotient/csapi/versions.h>
|
#include <Quotient/csapi/versions.h>
|
||||||
#include <Quotient/database.h>
|
|
||||||
#include <Quotient/jobs/downloadfilejob.h>
|
#include <Quotient/jobs/downloadfilejob.h>
|
||||||
#include <Quotient/qt_connection_util.h>
|
#include <Quotient/qt_connection_util.h>
|
||||||
#include <Quotient/room.h>
|
#include <Quotient/room.h>
|
||||||
@@ -482,23 +481,6 @@ QCoro::Task<void> NeoChatConnection::setupPushNotifications(QString endpoint)
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
QString NeoChatConnection::deviceKey() const
|
|
||||||
{
|
|
||||||
return edKeyForUserDevice(userId(), deviceId());
|
|
||||||
}
|
|
||||||
|
|
||||||
QString NeoChatConnection::encryptionKey() const
|
|
||||||
{
|
|
||||||
auto query = database()->prepareQuery(u"SELECT curveKey FROM tracked_devices WHERE matrixId=:matrixId AND deviceid=:deviceId LIMIT 1;"_s);
|
|
||||||
query.bindValue(u":matrixId"_s, userId());
|
|
||||||
query.bindValue(u":deviceId"_s, deviceId());
|
|
||||||
database()->execute(query);
|
|
||||||
if (!query.next()) {
|
|
||||||
return {};
|
|
||||||
}
|
|
||||||
return query.value(0).toString();
|
|
||||||
}
|
|
||||||
|
|
||||||
bool NeoChatConnection::isOnline() const
|
bool NeoChatConnection::isOnline() const
|
||||||
{
|
{
|
||||||
return m_isOnline;
|
return m_isOnline;
|
||||||
|
|||||||
@@ -31,8 +31,6 @@ class NeoChatConnection : public Quotient::Connection
|
|||||||
* Set to an empty string to remove the label.
|
* Set to an empty string to remove the label.
|
||||||
*/
|
*/
|
||||||
Q_PROPERTY(QString label READ label WRITE setLabel NOTIFY labelChanged)
|
Q_PROPERTY(QString label READ label WRITE setLabel NOTIFY labelChanged)
|
||||||
Q_PROPERTY(QString deviceKey READ deviceKey CONSTANT)
|
|
||||||
Q_PROPERTY(QString encryptionKey READ encryptionKey CONSTANT)
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief The model with the account's 3PIDs.
|
* @brief The model with the account's 3PIDs.
|
||||||
@@ -180,9 +178,6 @@ public:
|
|||||||
// the reference could be destroyed before the task is finished
|
// the reference could be destroyed before the task is finished
|
||||||
QCoro::Task<void> setupPushNotifications(QString endpoint);
|
QCoro::Task<void> setupPushNotifications(QString endpoint);
|
||||||
|
|
||||||
QString deviceKey() const;
|
|
||||||
QString encryptionKey() const;
|
|
||||||
|
|
||||||
bool isOnline() const;
|
bool isOnline() const;
|
||||||
|
|
||||||
LinkPreviewer *previewerForLink(const QUrl &link);
|
LinkPreviewer *previewerForLink(const QUrl &link);
|
||||||
|
|||||||
Reference in New Issue
Block a user