Don't let you open safe PDFs in dangerzone

This commit is contained in:
Micah Lee 2020-01-07 17:12:23 -08:00
parent e85191b498
commit 0aa7ff5f7c
No known key found for this signature in database
GPG key ID: 403C2657CD994F73

View file

@ -242,7 +242,10 @@ class Common(object):
if os.path.splitext(filename)[1] == ".desktop":
desktop_entry = DesktopEntry(full_filename)
if "application/pdf" in desktop_entry.getMimeTypes():
if (
"application/pdf" in desktop_entry.getMimeTypes()
and desktop_entry.getName() != "dangerzone"
):
pdf_viewers[
desktop_entry.getName()
] = desktop_entry.getExec()