I think it is related. Lets talk about this today at meeting.
I think we should write self explainable code. Simple and a programmer should not look at more then 10 lines each time.
We should think in closed blocks which are easy to test. How you suggest testing this one big function?
If each block is well testing then everything is easier.

You also mentioned you want to add two tests for this method. I think this should be done in this release.
I can share the effort.