fix recovery handler