Added better error message to Rest core client