details
refactoring and variables renaming