mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:07:46 +00:00
Assistant: Avoid an unnecessary copy of the results list
This commit is contained in:
parent
55f4d468ad
commit
c087ba24b9
1 changed files with 2 additions and 2 deletions
|
@ -84,7 +84,7 @@ public:
|
|||
{
|
||||
}
|
||||
|
||||
Function<void(Vector<NonnullRefPtr<Result const>>)> on_new_results;
|
||||
Function<void(Vector<NonnullRefPtr<Result const>>&&)> on_new_results;
|
||||
|
||||
void search(DeprecatedString const& query)
|
||||
{
|
||||
|
@ -131,7 +131,7 @@ private:
|
|||
return a->score() > b->score();
|
||||
});
|
||||
|
||||
on_new_results(all_results);
|
||||
on_new_results(move(all_results));
|
||||
}
|
||||
|
||||
AppState& m_state;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue