aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinus Jahn <lnj@kaidan.im>2022-08-08 18:36:02 +0200
committerLinus Jahn <lnj@kaidan.im>2022-08-08 18:36:02 +0200
commit619b431b29ff7e4e2ccfab1121fd9ecd848cd0a7 (patch)
tree126bffe3d3c2d19003a83e4d253799d095322093
parent35ea54219281bf256b9c990e52025e43c92f3d02 (diff)
downloadqxmpp-619b431b29ff7e4e2ccfab1121fd9ecd848cd0a7.tar.gz
FutureUtils: chain: Pass future as const&
The move overload hasn't any advantages here as the QFutureWatcher also takes QFuture const &.
-rw-r--r--src/base/QXmppFutureUtils_p.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/base/QXmppFutureUtils_p.h b/src/base/QXmppFutureUtils_p.h
index 311b2752..bf8c2f35 100644
--- a/src/base/QXmppFutureUtils_p.h
+++ b/src/base/QXmppFutureUtils_p.h
@@ -104,7 +104,7 @@ void await(const QFuture<void> &future, QObject *context, Handler handler)
}
template<typename Result, typename Input, typename Converter>
-auto chain(QFuture<Input> &&source, QObject *context, Converter task) -> QFuture<Result>
+auto chain(const QFuture<Input> &source, QObject *context, Converter task) -> QFuture<Result>
{
QFutureInterface<Result> resultInterface(QFutureInterfaceBase::Started);