use global setting
refactor