<commit_before>function TransactionGenerationController($scope, $modal, userService, walletTransactionService){
  
  $scope.prepareTransaction = function(txType, rawdata, from, $modalScope){
    var addressData = userService.getAddress(from);
    var pubKey = null;
    if(addressData.pubkey)
      pubKey= addressData.pubkey;
    else{
      var privKey = new Bitcoin.ECKey.decodeEncryptedFormat(addressData.privkey, addressData.address); // Using address as temporary password
      pubKey = privKey.getPubKeyHex();
    }
    var data = rawdata instanceof Array ? rawdata : [rawdata];

    pushOrderedTransactions(data,0);
    
    function pushOrderedTransactions(transactions,index){
      var txdata = transactions[index];
      txdata['pubkey'] = pubKey;
      $scope.TxPromise = walletTransactionService.getUnsignedTransaction(txType,txdata);
      $scope.TxPromise.then(function(successData) {
        var successData = successData.data;
        if (successData.status != 200 && successData.status != "OK") { /* Backwards compatibility for mastercoin-tools send API */
          $modalScope.waiting = false;
          $modalScope.transactionError = true;
          $modalScope.error = 'Error preparing transaction: ' + successData.error || successData.data; /* Backwards compatibility for mastercoin-tools send API */
        } else {<commit_msg>Cast the pubkey to Upper Case<commit_after>function TransactionGenerationController($scope, $modal, userService, walletTransactionService){
  
  $scope.prepareTransaction = function(txType, rawdata, from, $modalScope){
    var addressData = userService.getAddress(from);
    var pubKey = null;
    if(addressData.pubkey)
      pubKey= addressData.pubkey.toUpperCase();
    else{
      var privKey = new Bitcoin.ECKey.decodeEncryptedFormat(addressData.privkey, addressData.address); // Using address as temporary password
      pubKey = privKey.getPubKeyHex();
    }
    var data = rawdata instanceof Array ? rawdata : [rawdata];

    pushOrderedTransactions(data,0);
    
    function pushOrderedTransactions(transactions,index){
      var txdata = transactions[index];
      txdata['pubkey'] = pubKey;
      $scope.TxPromise = walletTransactionService.getUnsignedTransaction(txType,txdata);
      $scope.TxPromise.then(function(successData) {
        var successData = successData.data;
        if (successData.status != 200 && successData.status != "OK") { /* Backwards compatibility for mastercoin-tools send API */
          $modalScope.waiting = false;
          $modalScope.transactionError = true;
          $modalScope.error = 'Error preparing transaction: ' + successData.error || successData.data; /* Backwards compatibility for mastercoin-tools send API */
        } else {
{'fraction_non_alphanumeric': 0.10262965668371074, 'fraction_numerical': 0.0029218407596785976, 'mean_word_length': 3.847787610619469, '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': '7577470', 'n_tokens_mistral': 737, 'n_tokens_neox': 728, 'n_words': 167}