Backport fix for https://bugs.dojotoolkit.org/ticket/15561
 from 1.10 commit: https://github.com/dojo/dojox/commit/f4a8237b8301c0db7b49a316161f5bcbbfcdb39c