<commit_before>'use strict';

(function (module) {
  var moonData = {};
  var dataContent;

  // Filter function for matching month and year vars from form
  function filterFormData(value) {
    if (value.date.slice(0, 2) === moonController.month) {
      if (value.date.slice(6, 10) === moonController.year) {
        return value;
      }
    }
  }

  // Sort function to arrange days in ascending order
  function sortDays(days) {
    days.sort((a, b) => (a) - (b));
  }

  // JSON call to get filtered data
  moonData.getData = function (callback) {
    $.getJSON('../../data/cityData.json')
      .then(function (jsonData) {
        dataContent = jsonData.filter(filterFormData);
        console.log('first stage');
        return jsonData.filter(filterFormData);
      })
      .then(function (dataContent) {
        moonData.days = dataContent.map(datum => datum.date.slice(3, 5))
          .reduce(function (a, b) {
            if (a.indexOf(b) < 0) a.push(b);
            return a;
          }, []);
        sortDays(moonData.days);
        console.log('second stage');
        return moonData.days;
      })
      .then(function (days) {<commit_msg>removed console logs<commit_after>'use strict';

(function (module) {
  var moonData = {};
  var dataContent;

  // Filter function for matching month and year vars from form
  function filterFormData(value) {
    if (value.date.slice(0, 2) === moonController.month) {
      if (value.date.slice(6, 10) === moonController.year) {
        return value;
      }
    }
  }

  // Sort function to arrange days in ascending order
  function sortDays(days) {
    days.sort((a, b) => (a) - (b));
  }

  // JSON call to get filtered data
  moonData.getData = function (callback) {
    $.getJSON('../../data/cityData.json')
      .then(function (jsonData) {
        dataContent = jsonData.filter(filterFormData);
        return jsonData.filter(filterFormData);
      })
      .then(function (dataContent) {
        moonData.days = dataContent.map(datum => datum.date.slice(3, 5))
          .reduce(function (a, b) {
            if (a.indexOf(b) < 0) a.push(b);
            return a;
          }, []);
        sortDays(moonData.days);
        return moonData.days;
      })
      .then(function (days) {
{'fraction_non_alphanumeric': 0.14564831261101244, 'fraction_numerical': 0.007104795737122558, 'mean_word_length': 2.357675111773472, 'pattern_counts': {'":': 0, '<': 5, '<?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': '7222793', 'n_tokens_mistral': 717, 'n_tokens_neox': 701, 'n_words': 166}