"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var change_1 = require("./change");
function unionMemberRemoved(union, type) {
    return {
        criticality: {
            level: change_1.CriticalityLevel.Breaking,
            reason: 'Removing a union member from a union can cause existing queries that use this union member in a fragment spread to error.',
        },
        message: "Member '" + type.name + "' was removed from Union type '" + union.name + "'",
        path: union.name,
    };
}
exports.unionMemberRemoved = unionMemberRemoved;
function unionMemberAdded(union, type) {
    return {
        criticality: {
            level: change_1.CriticalityLevel.Breaking,
            reason: 'Adding a possible type to Unions may break existing clients that were not programming defensively against a new possible type.',
        },
        message: "Member '" + type.name + "' was added to Union type '" + union.name + "'",
        path: union.name,
    };
}
exports.unionMemberAdded = unionMemberAdded;
//# sourceMappingURL=union.js.map