mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-16 20:49:00 -04:00
Only show overlay when content is outside the printable area
The overlay was showing for any invalid pdf - we only want to show the overlay for invalid pdf files where there is content outside the printable area.
This commit is contained in:
@@ -181,7 +181,7 @@ def view_letter_upload_as_preview(service_id, file_id):
|
||||
|
||||
page = request.args.get('page')
|
||||
|
||||
if metadata['status'] == 'invalid':
|
||||
if metadata.get('message') == 'content-outside-printable-area':
|
||||
return TemplatePreview.from_invalid_pdf_file(pdf_file, page)
|
||||
else:
|
||||
return TemplatePreview.from_valid_pdf_file(pdf_file, page)
|
||||
|
||||
Reference in New Issue
Block a user