Fix function removed bug