Add dependency & remove useless code