Update documentation
Merging duplicated code