Fix mixed-up error messages

The too many pages error was being returned when the file couldn’t be
read. This commit corrects the error message, and adds a test to make
sure this case is covered.
This commit is contained in:
Chris Hill-Scott
2020-01-20 15:54:07 +00:00
parent 1fc0f58541
commit 34f209a08b
2 changed files with 15 additions and 2 deletions

View File

@@ -610,8 +610,8 @@ LETTER_VALIDATION_MESSAGES = {
'<br>Save a new copy of your file and try again.'
),
'summary': (
'Letters must be 10 pages or less. <br>'
'This letter is {page_count} pages long.'
'Validation failed because Notify cannot read this PDF.<br>'
'Save a new copy of your file and try again.'
),
},
'address-is-empty': {