"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.beginEventEmitter = void 0;
const events_1 = require("events");
function beginEventEmitter(o) {
    const ee = new events_1.EventEmitter();
    o.on = (eventName, cb) => {
        ee.on(eventName, cb);
        return o;
    };
    o.once = (eventName, cb) => {
        ee.on(eventName, cb);
        return o;
    };
    o.emit = ee.emit.bind(ee);
    return ee;
}
exports.beginEventEmitter = beginEventEmitter;
