Prevent undefined error if no input or output is available for an operation