feat: quit preview gracefully if Info.plist not found

This commit is contained in:
relikd
2025-11-06 01:52:05 +01:00
parent cfb6b17bc7
commit 21c21ec059
4 changed files with 24 additions and 3 deletions

View File

@@ -24,7 +24,8 @@ class PreviewViewController: NSViewController, QLPreviewingController {
func preparePreviewOfFile(at url: URL) async throws {
let meta = MetaInfo(url)
let html = PreviewGenerator(meta).generate(
// throws an exception if appPlist not found. Thus allowing another QuickLook plugin to try
let html = try PreviewGenerator(meta).generate(
template: try bundleFile(filename: "template", ext: "html"),
css: try bundleFile(filename: "style", ext: "css"),
)