Skip to content

Commit 6518bf8

Browse files
committed
add versioning to plugin settings
1 parent f292456 commit 6518bf8

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Flow.Launcher.Infrastructure/UserSettings/PluginSettings.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using System.Collections.Generic;
1+
using System.Collections.Generic;
22
using Flow.Launcher.Plugin;
33

44
namespace Flow.Launcher.Infrastructure.UserSettings
@@ -22,6 +22,9 @@ public void UpdatePluginSettings(List<PluginMetadata> metadatas)
2222
if (metadata.ID == "572be03c74c642baae319fc283e561a8" && metadata.ActionKeywords.Count != settings.ActionKeywords.Count)
2323
settings.ActionKeywords = metadata.ActionKeywords;
2424

25+
if (string.IsNullOrEmpty(settings.Version))
26+
settings.Version = metadata.Version;
27+
2528
if (settings.ActionKeywords?.Count > 0)
2629
{
2730
metadata.ActionKeywords = settings.ActionKeywords;
@@ -35,6 +38,7 @@ public void UpdatePluginSettings(List<PluginMetadata> metadatas)
3538
{
3639
ID = metadata.ID,
3740
Name = metadata.Name,
41+
Version = metadata.Version,
3842
ActionKeywords = metadata.ActionKeywords,
3943
Disabled = metadata.Disabled
4044
};
@@ -46,6 +50,7 @@ public class Plugin
4650
{
4751
public string ID { get; set; }
4852
public string Name { get; set; }
53+
public string Version { get; set; }
4954
public List<string> ActionKeywords { get; set; } // a reference of the action keywords from plugin manager
5055

5156
/// <summary>

0 commit comments

Comments
 (0)