<commit_before>'use strict'

const Word = require('../models/word')

module.exports.getWord = ({params: {correct_word}}, res, next) => {
  Word.getSingleWord(correct_word)
  .then( (word) => {
    res.status(200).json(word)
  })
  .catch( (error) => {
    next(error)
  })
}

module.exports.addWord = ({body}, res, next) => {
  console.log('body', body)
  Word.forge(body)
  .save()
  .then(() => res.status(201).json({"msg": "good"}))
  .catch((error) => {
    next(error)
  })
}<commit_msg>deleted console.log<commit_after>'use strict'

const Word = require('../models/word')

module.exports.getWord = ({params: {correct_word}}, res, next) => {
  Word.getSingleWord(correct_word)
  .then( (word) => {
    res.status(200).json(word)
  })
  .catch( (error) => {
    next(error)
  })
}

module.exports.addWord = ({body}, res, next) => {
  Word.forge(body)
  .save()
  .then(() => res.status(201).json({"msg": "good"}))
  .catch((error) => {
    next(error)
  })
}
{'fraction_non_alphanumeric': 0.2338877338877339, 'fraction_numerical': 0.012474012474012475, 'mean_word_length': 3.6298076923076925, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 15, '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': '1325135', 'n_tokens_mistral': 376, 'n_tokens_neox': 365, 'n_words': 59}