adds documentation
removes redundant passing of an extra parameter