refact inject part