diff options
Diffstat (limited to 'libmat')
| -rw-r--r-- | libmat/office.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/libmat/office.py b/libmat/office.py index 2f6fff0..d020c46 100644 --- a/libmat/office.py +++ b/libmat/office.py | |||
| @@ -127,10 +127,7 @@ class PdfStripper(parser.GenericParser): | |||
| 127 | ''' Check if the file is clean from harmful metadatas | 127 | ''' Check if the file is clean from harmful metadatas |
| 128 | ''' | 128 | ''' |
| 129 | document = Poppler.Document.new_from_file(self.uri, self.password) | 129 | document = Poppler.Document.new_from_file(self.uri, self.password) |
| 130 | for key in self.meta_list: | 130 | return not any(document.get_property(key) for key in self.meta_list) |
| 131 | if document.get_property(key): | ||
| 132 | return False | ||
| 133 | return True | ||
| 134 | 131 | ||
| 135 | def remove_all(self): | 132 | def remove_all(self): |
| 136 | ''' Opening the PDF with poppler, then doing a render | 133 | ''' Opening the PDF with poppler, then doing a render |
