import { session } from "./State";
export var wrapSessionMethod = function (method) { return function () {
    var args = [];
    for (var _i = 0; _i < arguments.length; _i++) {
        args[_i] = arguments[_i];
    }
    if (session === undefined) {
        throw new Error("No session has been registered for compat modules");
    }
    var sessionMethod = session[method];
    return sessionMethod.apply(session, args);
}; };
