Incorrect configuration values are currently handled individually for each condition, resulting in a lot of repetitive operations. This commit adds two new private functions to report errors to the user and end execution of the script.