unit: centralize in unit.go