Fixed bug in RenderToSTringControllerTemplate when prepare is called multiple times.