File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Plugins/Flow.Launcher.Plugin.BrowserBookmark Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -162,7 +162,8 @@ ORDER BY i.width DESC
162162
163163 if ( imageData is not { Length : > 0 } )
164164 return ;
165-
165+
166+ // Check if the image data is compressed (GZip)
166167 if ( imageData . Length > 2 && imageData [ 0 ] == 0x1f && imageData [ 1 ] == 0x8b )
167168 {
168169 using var inputStream = new MemoryStream ( imageData ) ;
@@ -171,9 +172,9 @@ ORDER BY i.width DESC
171172 gZipStream . CopyTo ( outputStream ) ;
172173 imageData = outputStream . ToArray ( ) ;
173174 }
174-
175+
176+ // Convert the image data to WebP format
175177 var webpData = FaviconHelper . TryConvertToWebp ( imageData ) ;
176-
177178 if ( webpData != null )
178179 {
179180 var faviconPath = Path . Combine ( _faviconCacheDir , $ "firefox_{ domain } _{ iconId } .webp") ;
Original file line number Diff line number Diff line change @@ -121,4 +121,4 @@ public static byte[] TryConvertToWebp(byte[] data)
121121
122122 return null ;
123123 }
124- }
124+ }
You can’t perform that action at this time.
0 commit comments