I think I understand the problem well enough now to fix the bug and not cause any undesired effects - giving this another shot
Bumping version number to 4.1.3 for release