moov-io / imagecashletter

X9’s Specifications for ICL (Image Cash Letter) to provide Check 21 services. The HTTP server is available in a Docker image and the Go package is available.
https://moov-io.github.io/imagecashletter/
Apache License 2.0
60 stars 39 forks source link

Fix the order written by writeReturnImageView to be as expected by the FRB #360

Closed smithbk closed 3 months ago

smithbk commented 3 months ago

What were you trying to do?

Write a return check with image which is acceptable to the FRB (Federal Reserve Bank).

What did you expect to see?

FRB asks that imageViewDetail should immediately be followed by its corresponding data and analysis. I expected this to be the case for both check images and return images.

What did you see?

I saw the correct order to check images but not for return images. The problem is that the writeReturnImageView function in writer.go writes all detail records first, then data, and then analysis records.

How can we reproduce the problem?

Write a return check with image.

smithbk commented 3 months ago

PR submitted at https://github.com/moov-io/imagecashletter/pull/361