remove local functions