<commit_before>    // create a list of all goals
    function setGoals(data) {
        $('.dashboard-goals-list').attr('style', 'display:none;');
        $('#goalOverview'+data.overview.id).attr('style', 'display:block;');
        // create box for each goal
        for(var i = 0; i < data.goals.length; i++) {
            addGoalBox(data, i);
        }
    }

    function addGoalBox(data, i) {
        var chart = $('#goal'+data.goals[i]['id']+' .dashboard-goals-list__chart');

         $('#goal'+data.goals[i]['id']+' .dashboard-goals-list__item__title').html(data.goals[i]['name']);
         $('#goal'+data.goals[i]['id']+' .dashboard-goals-list__item__number').html('<strong>' + data.goals[i]['visits'] + '</strong> conversions');

        // render the chart
        new Morris.Area({<commit_msg>tabswitch bugfix<commit_after>    // create a list of all goals
    function setGoals(data) {
        $('.dashboard-goals-list').attr('style', 'display:none;');
        $('#goalOverview'+data.overview.id).attr('style', 'display:block;');
        // create box for each goal
        for(var i = 0; i < data.goals.length; i++) {
            addGoalBox(data, i);
        }
    }

    function addGoalBox(data, i) {
        $('#goal'+data.goals[i]['id']+' .dashboard-goals-list__chart').html('');
        var chart = $('#goal'+data.goals[i]['id']+' .dashboard-goals-list__chart');

         $('#goal'+data.goals[i]['id']+' .dashboard-goals-list__item__title').html(data.goals[i]['name']);
         $('#goal'+data.goals[i]['id']+' .dashboard-goals-list__item__number').html('<strong>' + data.goals[i]['visits'] + '</strong> conversions');

        // render the chart
        new Morris.Area({
{'fraction_non_alphanumeric': 0.21631205673758866, 'fraction_numerical': 0.001182033096926714, 'mean_word_length': 3.021377672209026, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 7, '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': '3110174', 'n_tokens_mistral': 565, 'n_tokens_neox': 564, 'n_words': 92}