Repair of few functions and adding simple map