Fixed an error related to an xml call to length rather than maxLength.