<commit_before>#!/bin/bash

/**
 * Payment-Server - A Payment Protocol demonstration.
 * Copyright (c) 2014, BitPay
 * https://github.com/bitpay/bitcore
 */

/**
 * Modules
 */

var https = require('https');
var fs = require('fs');
var path = require('path');
var qs = require('querystring');
var crypto = require('crypto');
var assert = require('assert');

// Disable strictSSL
process.env['NODE_TLS_REJECT_UNAUTHORIZED'] = '0';

/**
 * Dependencies
 */

var argv = require('optimist').argv;
var express = require('express');
var bitcore = require('../../');

var PayPro = bitcore.PayPro;
var Transaction = bitcore.Transaction;
var TransactionBuilder = bitcore.TransactionBuilder;

/**
 * Variables
 */

var isNode = !argv.b && !argv.browser;

var app = express();

var x509 = {
  priv: fs.readFileSync(__dirname + '/../../test/data/x509.key'),
  pub: fs.readFileSync(__dirname + '/../../test/data/x509.pub'),
  der: fs.readFileSync(__dirname + '/../../test/data/x509.der'),
  pem: fs.readFileSync(__dirname + '/../../test/data/x509.crt')
};

var server = https.createServer({
  key: fs.readFileSync(__dirname + '/../../test/data/x509.key'),
  cert: fs.readFileSync(__dirname + '/../../test/data/x509.crt')
});

/**
 * Ignore Cache Headers
 * Allow CORS
 * Accept Payments
 */

app.use(function(req, res, next) {
  var setHeader = res.setHeader;

  res.setHeader = function(name) {<commit_msg>paypro: example - allow user to set options when using example as a module.<commit_after>#!/bin/bash

/**
 * Payment-Server - A Payment Protocol demonstration.
 * Copyright (c) 2014, BitPay
 * https://github.com/bitpay/bitcore
 */

/**
 * Modules
 */

var https = require('https');
var fs = require('fs');
var path = require('path');
var qs = require('querystring');
var crypto = require('crypto');
var assert = require('assert');

// Disable strictSSL
process.env['NODE_TLS_REJECT_UNAUTHORIZED'] = '0';

/**
 * Dependencies
 */

var argv = require('optimist').argv;
var express = require('express');
var bitcore = require('../../');

var PayPro = bitcore.PayPro;
var Transaction = bitcore.Transaction;
var TransactionBuilder = bitcore.TransactionBuilder;

/**
 * Variables
 */

var x509 = {
  priv: fs.readFileSync(__dirname + '/../../test/data/x509.key'),
  pub: fs.readFileSync(__dirname + '/../../test/data/x509.pub'),
  der: fs.readFileSync(__dirname + '/../../test/data/x509.der'),
  pem: fs.readFileSync(__dirname + '/../../test/data/x509.crt')
};

var server = https.createServer({
  key: fs.readFileSync(__dirname + '/../../test/data/x509.key'),
  cert: fs.readFileSync(__dirname + '/../../test/data/x509.crt')
});

server.setOptions = function(options) {
  argv = options;
};

var isNode = !argv.b && !argv.browser;

var app = express();

/**
 * Ignore Cache Headers
 * Allow CORS
 * Accept Payments
 */

app.use(function(req, res, next) {
  var setHeader = res.setHeader;

  res.setHeader = function(name) {
{'fraction_non_alphanumeric': 0.19505494505494506, 'fraction_numerical': 0.017857142857142856, 'mean_word_length': 3.638535031847134, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, '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': '1971576', 'n_tokens_mistral': 1014, 'n_tokens_neox': 965, 'n_words': 214}