We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 75522bc + 37a2d71 commit 75df811Copy full SHA for 75df811
include/graphqlservice/GraphQLService.h
@@ -600,7 +600,11 @@ class [[nodiscard("unnecessary construction")]] AwaitableObject
600
AwaitableObject(
601
U&& value, std::enable_if_t<!std::is_assignable_v<T, U> && is_future<U>::value>* = nullptr)
602
: _value(std::async([value = std::forward<U>(value)]() mutable {
603
- return GraphQLBuilder<T>::build(value.get());
+ if constexpr(std::is_assignable_v<T, decltype(value.get())>){
604
+ return value.get();
605
+ }else{
606
+ return GraphQLBuilder<T>::build(value.get());
607
+ }
608
}))
609
{
610
}
0 commit comments