Let Future::then call callbacks outside of the catch handler
[folly.git] / folly / futures / QueuedImmediateExecutor.cpp
index 5a924afda4e3b9b6133fd00a11720ee0fbe07b29..1d2aeea75bb3e0c9517024ff1888dd317742ce38 100644 (file)
@@ -30,7 +30,7 @@ void QueuedImmediateExecutor::addStatic(Func callback) {
       q_->pop();
     }
   } else {
-    q_->push(callback);
+    q_->push(std::move(callback));
   }
 }