Improve Issue 10220 fix.

Improves pull #1329.

Issue URL: http://d.puremagic.com/issues/show_bug.cgi?id=10220