Make code modulized