@@ -17,7 +17,7 @@ public class Main : ISettingProvider, IPlugin, IReloadable, IPluginI18n, IContex
1717{
1818 private static PluginInitContext _context ;
1919
20- private static List < Bookmark > _cachedBookmarks = new List < Bookmark > ( ) ;
20+ private static List < Bookmark > _cachedBookmarks = new ( ) ;
2121
2222 private static Settings _settings ;
2323
@@ -107,9 +107,9 @@ public List<Result> Query(Query query)
107107 }
108108 }
109109
110- private static Channel < byte > _refreshQueue = Channel . CreateBounded < byte > ( 1 ) ;
110+ private static readonly Channel < byte > _refreshQueue = Channel . CreateBounded < byte > ( 1 ) ;
111111
112- private static SemaphoreSlim _fileMonitorSemaphore = new ( 1 , 1 ) ;
112+ private static readonly SemaphoreSlim _fileMonitorSemaphore = new ( 1 , 1 ) ;
113113
114114 private static async Task MonitorRefreshQueueAsync ( )
115115 {
@@ -143,12 +143,13 @@ internal static void RegisterBookmarkFile(string path)
143143 return ;
144144 }
145145
146- var watcher = new FileSystemWatcher ( directory ! ) ;
147- watcher . Filter = Path . GetFileName ( path ) ;
148-
149- watcher . NotifyFilter = NotifyFilters . FileName |
150- NotifyFilters . LastWrite |
151- NotifyFilters . Size ;
146+ var watcher = new FileSystemWatcher ( directory ! )
147+ {
148+ Filter = Path . GetFileName ( path ) ,
149+ NotifyFilter = NotifyFilters . FileName |
150+ NotifyFilters . LastWrite |
151+ NotifyFilters . Size
152+ } ;
152153
153154 watcher . Changed += static ( _ , _ ) =>
154155 {
@@ -197,7 +198,7 @@ public List<Result> LoadContextMenus(Result selectedResult)
197198 {
198199 return new List < Result > ( )
199200 {
200- new Result
201+ new ( )
201202 {
202203 Title = _context . API . GetTranslation ( "flowlauncher_plugin_browserbookmark_copyurl_title" ) ,
203204 SubTitle = _context . API . GetTranslation ( "flowlauncher_plugin_browserbookmark_copyurl_subtitle" ) ,
0 commit comments