Fixed occasional returning 'null' string.

As some Material id's didn't allow anything other than what the data value was, the string would return null.