Documentation updates and was more responsible with closing streams.