Skip to content

Commit

Permalink
Merge pull request #156 from companieshouse/fix/lp-397-office-address…
Browse files Browse the repository at this point in the history
…-postcode-error

lp-397 : pass current data to screen if re-render due to error
  • Loading branch information
lduranteau authored Jan 24, 2025
2 parents ca7a652 + 83b8585 commit 93e28cd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/presentation/controller/addressLookUp/Controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,10 @@ class AddressLookUpController extends AbstractController {

if (errors?.errors) {
pageRouting.errors = errors?.errors;
pageRouting.data = {
...pageRouting.data,
limitedPartnership
};

response.render(super.templateName(pageRouting.currentUrl), {
props: { ...pageRouting }
Expand Down

0 comments on commit 93e28cd

Please sign in to comment.