updated osm_errors logic