function handleResponse()

in automated-actions/AWS_EC2_INSTANCE_STORE_DRIVE_PERFORMANCE_DEGRADED/LambdaFunction.js [57:72]


    function handleResponse(err, data) {
        if (err) {                                                          // an error occurred
            if (err.code == 'DryRunOperation') {
                console.log(instances, region, err.message);
                callback(null, awsHealthSuccessMessage);
            } else {
                console.log(instances, region, err, err.stack);
                throw err;
            }

        } else {
            console.log(`Instance ${action}: `, instances, region);
            //return success
            callback(null, awsHealthSuccessMessage);
        }                                                                   // successful response
    }