refactoring: remove useless variable.
refactoring: DRY.
use default value.