Reads the first error carried by a program.
Program to read.
The error, or undefined when the program carries none.
undefined
const error = getFirstErrorBlock(response);if (error) throw new Error(error.message ?? error.source); Copy
const error = getFirstErrorBlock(response);if (error) throw new Error(error.message ?? error.source);
Reads the first error carried by a program.