Skip to content

Commit 10d353d

Browse files
committed
Returning actions
1 parent 9ca7c84 commit 10d353d

File tree

2 files changed

+7
-9
lines changed

2 files changed

+7
-9
lines changed

Flow.Launcher/Storage/QueryHistory.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ public void PopulateHistoryFromLegacyHistory()
3636
public void Add(Result result)
3737
{
3838
if (string.IsNullOrEmpty(result.OriginQuery.RawQuery)) return;
39+
if (string.IsNullOrEmpty(result.PluginID)) return;
3940

4041
// Maintain the max history limit
4142
if (LastOpenedHistoryItems.Count > _maxHistory)

Flow.Launcher/ViewModel/MainViewModel.cs

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1358,20 +1358,17 @@ private List<Result> GetHistoryItems(IEnumerable<LastOpenedHistoryItem> historyI
13581358
{
13591359
if (reflectResult.Action != null)
13601360
{
1361-
reflectResult.Action(c);
1361+
return reflectResult.Action(c);
13621362
}
1363-
else if (reflectResult.AsyncAction != null)
1363+
if (reflectResult.AsyncAction != null)
13641364
{
1365-
await reflectResult.AsyncAction(c);
1365+
return await reflectResult.AsyncAction(c);
13661366
}
13671367
return false;
13681368
}
1369-
else
1370-
{
1371-
App.API.BackToQueryResults();
1372-
App.API.ChangeQuery(h.Query);
1373-
return false;
1374-
}
1369+
App.API.BackToQueryResults();
1370+
App.API.ChangeQuery(h.Query);
1371+
return false;
13751372
},
13761373
Glyph = new GlyphInfo(FontFamily: "/Resources/#Segoe Fluent Icons", Glyph: "\uE81C")
13771374
};

0 commit comments

Comments
 (0)