put back in old code for m3s but left in the slight refactoring for easier testing
Merge pull request #518 from aglover/m3-redux-3

Put back in old code for m3s