fixes cssRules property read fail due to same-origin policy

Catches a silent error that will occur when trying to read the styleSheet.cssRules property from a file from another domain.

Fixes https://bugs.dojotoolkit.org/ticket/17535.