add docstring to newly refactored method