A community-supported supercharged document management system: scan, index and archive all your documents
Python aiangulararchivingdjangodmsdocument-managementdocument-management-systemllmmachine-learningocroptical-character-recognitionpdf
src/paperless/db.py: If encryption is disabled, just directly read the file contents
Mike Cronce3b6a3219f59e
diff --git a/src/paperless/db.py b/src/paperless/db.pyindex 49e4fea4b..07cef0024 100644--- a/src/paperless/db.py+++ b/src/paperless/db.py@@ -12,11 +12,15 @@ class GnuPG(object):@classmethoddef decrypted(cls, file_handle):+ if(not settings.ENABLE_ENCRYPTION):+ return file_handle.read()return cls.gpg.decrypt_file(file_handle, passphrase=settings.PASSPHRASE).data@classmethoddef encrypted(cls, file_handle):+ if(not settings.ENABLE_ENCRYPTION):+ return file_handle.read()return cls.gpg.encrypt_file(file_handle,recipients=None,