Stopped overwriting the document contents upon load.