<commit_before>'use strict';

function create (header, server, loadRequests) {
    const baseURL = `/imposters/${server.port}`;

    function createHeader (numberOfRequests, options) {
        const result = {
            protocol: header.protocol,
            port: server.port
        };

        if (!options.replayable) {
            result.numberOfRequests = numberOfRequests;
        }
        if (!options.list) {
            if (header.name) {
                result.name = header.name;
            }
            result.recordRequests = Boolean(header.recordRequests);

            Object.keys(server.metadata).forEach(key => {
                result[key] = server.metadata[key];
            });
        }
<commit_msg>Adding name to /imposters HTML page<commit_after>'use strict';

function create (header, server, loadRequests) {
    const baseURL = `/imposters/${server.port}`;

    function createHeader (numberOfRequests, options) {
        const result = {
            protocol: header.protocol,
            port: server.port
        };

        if (header.name) {
            result.name = header.name;
        }
        if (!options.replayable) {
            result.numberOfRequests = numberOfRequests;
        }
        if (!options.list) {
            result.recordRequests = Boolean(header.recordRequests);

            Object.keys(server.metadata).forEach(key => {
                result[key] = server.metadata[key];
            });
        }

{'fraction_non_alphanumeric': 0.11422708618331054, 'fraction_numerical': 0.0, 'mean_word_length': 1.8518518518518519, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4501159', 'n_tokens_mistral': 387, 'n_tokens_neox': 392, 'n_words': 75}