<commit_before>angular.module("angular-growl").directive("growl", ["$rootScope", "$sce",
  function($rootScope, $sce) {
    "use strict";

    return {
      restrict: 'A',
      templateUrl: 'templates/growl/growl.html',
      replace: false,
      scope: {
        reference: '@',
        inline: '@'
      },
      controller: ['$scope', '$timeout', 'growl',
        function($scope, $timeout, growl) {
          var onlyUnique = growl.onlyUnique();
          $scope.messages = [];
          var referenceId = $scope.reference || 0;
          $scope.inlineMessage = $scope.inline || growl.inlineMessages();

          function addMessage(message) {
            $timeout(function() {
              message.text = $sce.trustAsHtml(message.text);
              $scope.messages.push(message);

              if (message.ttl && message.ttl !== -1) {
                $timeout(function() {
                  $scope.deleteMessage(message);
                }, message.ttl);
              }
            }, true);<commit_msg>Fixes edge case where message text is not a string<commit_after>angular.module("angular-growl").directive("growl", ["$rootScope", "$sce",
  function($rootScope, $sce) {
    "use strict";

    return {
      restrict: 'A',
      templateUrl: 'templates/growl/growl.html',
      replace: false,
      scope: {
        reference: '@',
        inline: '@'
      },
      controller: ['$scope', '$timeout', 'growl',
        function($scope, $timeout, growl) {
          var onlyUnique = growl.onlyUnique();
          $scope.messages = [];
          var referenceId = $scope.reference || 0;
          $scope.inlineMessage = $scope.inline || growl.inlineMessages();

          function addMessage(message) {
            $timeout(function() {
              message.text = $sce.trustAsHtml(String(message.text));
              $scope.messages.push(message);

              if (message.ttl && message.ttl !== -1) {
                $timeout(function() {
                  $scope.deleteMessage(message);
                }, message.ttl);
              }
            }, true);
{'fraction_non_alphanumeric': 0.15488215488215487, 'fraction_numerical': 0.001924001924001924, 'mean_word_length': 1.9545454545454546, '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': '621431', 'n_tokens_mistral': 591, 'n_tokens_neox': 576, 'n_words': 106}