"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.updateReflectMetadata = updateReflectMetadata;
const getReflectMetadata_1 = require("./getReflectMetadata");
function updateReflectMetadata(target, metadataKey, buildDefaultValue, callback, propertyKey) {
    const metadata = (0, getReflectMetadata_1.getReflectMetadata)(target, metadataKey, propertyKey) ?? buildDefaultValue();
    const updatedMetadata = callback(metadata);
    Reflect.defineMetadata(metadataKey, updatedMetadata, target, propertyKey);
}
//# sourceMappingURL=updateReflectMetadata.js.map