{"size": 715, "ext": "js", "max_stars_repo_path": "lotionjs_server/node_modules/lotion/dist/discovery.js", "max_stars_repo_name": "painforever/blockchain_admin", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "lotionjs_server/node_modules/lotion/dist/discovery.js", "max_issues_repo_name": "painforever/blockchain_admin", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "lotionjs_server/node_modules/lotion/dist/discovery.js", "max_forks_repo_name": "painforever/blockchain_admin", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 28.6, "max_line_length": 62, "alphanum_fraction": 0.6195804196}
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var createServer = require('peer-channel').createServer;
var serve = require('jpfs').serve;
function announce(GCI, rpcPort) {
    var server = createServer(function (socket) {
        socket.send('' + rpcPort);
        socket.end();
        socket.on('error', function (e) { });
    });
    server.listen('fullnode:' + GCI);
    return server;
}
function default_1(info) {
    var announceServer = announce(info.GCI, info.rpcPort);
    var genesisServer = serve(info.genesis);
    return {
        close: function () {
            announceServer.close();
            genesisServer.close();
        }
    };
}
exports.default = default_1;
