<commit_before>angular.module('starter.controllers')

.controller('QuestionRepliesCtrl', ['$scope', '$stateParams', 'Processes', 'Users', function($scope, $stateParams, Processes, Users) {

  Processes.getQuestion($stateParams.processId, $stateParams.ruleId, $stateParams.questionId)
    .success(function (response) {
      $scope.replies = response;
    })

    .error(function (error) {
      console.log(error);
    });

  $scope.addReply = function (reply) {
    var data = {from: Users.getUser()['name'], text: reply}

    Processes.setRuleQuestionReply($stateParams.processId, $stateParams.ruleId, $stateParams.questionId, data)
      .success(function (response) {
        $scope.replies.push(response)
      })
      .error(function(error) {
        console.log(error)
      });
  };

  $scope.like = function (replyId) {
    Processes.setRuleQuestionReplyLikes($stateParams.processId, $stateParams.ruleId, $stateParams.questionId, replyId)
      .success(function (response) {
        console.log(response)
        $scope.replies = response
      })
      .error(function(error) {
        console.log(error)
      });
  };
}]);<commit_msg>Retira console.log<commit_after>angular.module('starter.controllers')

.controller('QuestionRepliesCtrl', ['$scope', '$stateParams', 'Processes', 'Users', function($scope, $stateParams, Processes, Users) {

  Processes.getQuestion($stateParams.processId, $stateParams.ruleId, $stateParams.questionId)
    .success(function (response) {
      $scope.replies = response;
    })

    .error(function (error) {
      console.log(error);
    });

  $scope.addReply = function (reply) {
    var data = {from: Users.getUser()['name'], text: reply}

    Processes.setRuleQuestionReply($stateParams.processId, $stateParams.ruleId, $stateParams.questionId, data)
      .success(function (response) {
        $scope.replies.push(response)
      })
      .error(function(error) {
        console.log(error)
      });
  };

  $scope.like = function (replyId) {
    Processes.setRuleQuestionReplyLikes($stateParams.processId, $stateParams.ruleId, $stateParams.questionId, replyId)
      .success(function (response) {
        $scope.replies = response
      })
      .error(function(error) {
        console.log(error)
      });
  };
}]);
{'fraction_non_alphanumeric': 0.15310162780466344, 'fraction_numerical': 0.0, 'mean_word_length': 3.612576064908722, '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': '921055', 'n_tokens_mistral': 703, 'n_tokens_neox': 698, 'n_words': 104}