added error handling for 500 and missing localised messages