<commit_before>/**
 * Is passed date is weekend?
 * @param {date|string} dirtyDate
 * @returns {boolean}
 */
var isWeekend = function(dirtyDate) {
  var date = new Date(dirtyDate);
  var day = date.getDay();

  if (day == 0 || day == 6) {
    return true;
  } else {
    return false;
  }
};

module.exports = isWeekend;
<commit_msg>Simplify isWeekend function<commit_after>/**
 * Is passed date is weekend?
 * @param {date|string} dirtyDate
 * @returns {boolean}
 */
var isWeekend = function(dirtyDate) {
  var date = new Date(dirtyDate);
  var day = date.getDay();
  return day == 0 || day == 6;
};

module.exports = isWeekend;

{'fraction_non_alphanumeric': 0.15079365079365079, 'fraction_numerical': 0.006349206349206349, 'mean_word_length': 3.605839416058394, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '3346832', 'n_tokens_mistral': 220, 'n_tokens_neox': 212, 'n_words': 63}