<commit_before>'use strict';

var _ = require('lodash');

function Enum(values) {

  var keys = [];
  var map = {};

  function add(id, name) {
    keys.push(id);
    map[id] = name;
  }

  if (values) {
    values.forEach(function(v) { add(v.id, v.name); });
  }

  return _.extend(map, {
    add: add,
    keys: function() { return keys; }
  });

}

module.exports = exports = {
  cardTypes: new Enum([
    { id: 'none', name: 'None' },
    { id: 'visa', name: 'VISA' },
    { id: 'masterCard', name: 'MasterCard' },
    { id: 'americanExpress', name: 'American Express' },
    { id: 'discover', name: 'Discover' },
    { id: 'dinersClub', name: 'Diners Club' },
    { id: 'jcb', name: 'JCB' },
    { id: 'laser', name: 'Laser' },
    { id: 'maestro', name: 'Maestro' }
  ]),
  cuisineTypes: new Enum([
    { id: 'African', name: 'African' },
    { id: 'American', name: 'American' },
    { id: 'Asian', name: 'Asian' },
    { id: 'Bakery', name: 'Bakery' },
    { id: 'Balkan', name: 'Balkan' },
    { id: 'BBQ', name: 'BBQ' },
    { id: 'Breakfast', name: 'Breakfast' },
    { id: 'British', name: 'British' },
    { id: 'Brunch', name: 'Brunch' },
    { id: 'Burgers', name: 'Burgers' },
    { id: 'Cafe', name: 'Cafe' },
    { id: 'Cantonese', name: 'Cantonese' },
    { id: 'Caribbean', name: 'Caribbean' },
    { id: 'Cheesesteaks', name: 'Cheesesteaks' },
    { id: 'Chicken', name: 'Chicken' },
    { id: 'Chinese', name: 'Chinese' },
    { id: 'Classic', name: 'Classic' },
    { id: 'Cuban', name: 'Cuban' },
    { id: 'Deli', name: 'Deli' },
    { id: 'Dessert', name: 'Dessert' },
    { id: 'Dim Sum', name: 'Dim Sum' },
    { id: 'English', name: 'English' },
    { id: 'Ethiopian', name: 'Ethiopian' },
    { id: 'Food Truck', name: 'Food Truck' },
    { id: 'French', name: 'French' },
    { id: 'Fresh Fruits', name: 'Fresh Fruits' },
    { id: 'Fusion', name: 'Fusion' },
    { id: 'Gluten-Free', name: 'Gluten-Free' },
    { id: 'Grinders', name: 'Grinders' },
    { id: 'Greek', name: 'Greek' },
    { id: 'Halal', name: 'Halal' },
    { id: 'Healthy', name: 'Healthy' },
    { id: 'Indian', name: 'Indian' },
    { id: 'Irish', name: 'Irish' },
    { id: 'Italian', name: 'Italian' },
    { id: 'Jamaican', name: 'Jamaican' },
    { id: 'Japanese', name: 'Japanese' },
    { id: 'Jewish', name: 'Jewish' },
    { id: 'Korean', name: 'Korean' },
    { id: 'Late Night', name: 'Late Night' },
    { id: 'Latin', name: 'Latin' },
    { id: 'Lebanese', name: 'Lebanese' },
    { id: 'Low Carb', name: 'Low Carb' },
    { id: 'Low Fat', name: 'Low Fat' },
    { id: 'Lunch Specials', name: 'Lunch Specials' },
    { id: 'Mandarin', name: 'Mandarin' },
    { id: 'Mediterranean', name: 'Mediterranean' },
    { id: 'Mexican', name: 'Mexican' },
    { id: 'Middle Eastern', name: 'Middle Eastern' },
    { id: 'Moroccan', name: 'Moroccan' },
    { id: 'Noodles', name: 'Noodles' },
    { id: 'Organic', name: 'Organic' },
    { id: 'Pakistani', name: 'Pakistani' },
    { id: 'Peruvian', name: 'Peruvian' },
    { id: 'Pizza', name: 'Pizza' },
    { id: 'Polish', name: 'Polish' },
    { id: 'Puerto Rican', name: 'Puerto Rican' },
    { id: 'Salads', name: 'Salads' },
    { id: 'Sandwiches', name: 'Sandwiches' },
    { id: 'Seafood', name: 'Seafood' },
    { id: 'Soul Food', name: 'Soul Food' },
    { id: 'Soup', name: 'Soup' },
    { id: 'Southern', name: 'Southern' },
    { id: 'Steakhouse', name: 'Steakhouse' },
    { id: 'Subs', name: 'Subs' },
    { id: 'Sushi', name: 'Sushi' },
    { id: 'Swedish', name: 'Swedish' },
    { id: 'Szechwan', name: 'Szechwan' },
    { id: 'Tapas', name: 'Tapas' },
    { id: 'Thai', name: 'Thai' },
    { id: 'Vegan', name: 'Vegan' },
    { id: 'Vegetarian', name: 'Vegetarian' },
    { id: 'Venezuelan', name: 'Venezuelan' },
    { id: 'Vietnamese', name: 'Vietnamese' },
    { id: 'Wings', name: 'Wings' }
  ]),
  day: new Enum([
    { id: 0, name: 'Sunday' },
    { id: 1, name: 'Monday' },
    { id: 2, name: 'Tuesday' },
    { id: 3, name: 'Wednesday' },
    { id: 4, name: 'Thursday' },
    { id: 5, name: 'Friday' },
    { id: 6, name: 'Saturday' }
  ]),
  deliveryTypes: new Enum([
    { id: 'unknown', name: 'unknown' },
    { id: 'delivery', name: 'delivery' },
    { id: 'pickup', name: 'pickup' }
  ]),
  eventTopics: new Enum([
    { id: 'event.orders.order.started', name: 'Order Started' },
    { id: 'event.orders.order.updated', name: 'Order Updated' },
    { id: 'event.orders.order.submitted', name: 'Order Submitted' },
    { id: 'event.orders.order.authorized', name: 'Order Authorized' },
    { id: 'event.orders.order.invoiced', name: 'Order Invoiced' },
    { id: 'event.orders.order.confirmed', name: 'Order Confirmed' },
    { id: 'event.orders.order.settled', name: 'Order Settled' },
    { id: 'event.orders.order.enroute', name: 'Order In Transit' },
    { id: 'event.orders.order.fulfilled', name: 'Order Fulfilled' },
    { id: 'event.orders.order.canceled', name: 'Order Canceled' },
    { id: 'event.orders.order.error', name: 'Order Error' },
    { id: 'event.orders.order.reminder', name: 'Order Reminder' },
    { id: 'event.orders.order.survey', name: 'Order Survey' },
    { id: 'event.orders.part.added', name: 'Diner Added' },
    { id: 'event.orders.part.submitted', name: 'Diner Submitted' },
    { id: 'event.orders.part.removed', name: 'Diner Removed' },
    { id: 'event.orders.part.reminder', name: 'Diner Reminder' },
    { id: 'event.orders.order.transmit', name: 'Ready to Transmit' },
    { id: 'event.orders.order.batchTransmit', name: 'Ready to Transmit (batch)' },
    { id: 'event.orders.order.confirm', name: 'Ready to Confirm' },
    { id: 'event.orders.order.batchVerify', name: 'Ready to Verify (batch)' },
    { id: 'event.orders.order.invite', name: 'Recurring Order Invite' },
    { id: 'event.restaurants.restaurant.verify-email', name: 'Restaurant Onboarding Email' },
    { id: 'event.restaurants.restaurant.verify-fax', name: 'Restaurant Onboarding Fax' },
    { id: 'messages.restaurant.claim', name: 'Restaurant Claimed' },
    { id: 'messages.change.restaurant.claim', name: 'Restaurant Claim Reviewed' },
    { id: 'event.vcn.reconciliation.settled', name: 'VCN Settlement' },
    { id: 'event.vcn.reconciliation.error', name: 'VCN Reconciliation Error' }
  ]),
  eventFilters: new Enum([
    { id: 'groupOrder', name: 'Group Orders' },
    { id: 'individualOrder', name: 'Individual Orders' },
    { id: 'cateringOrder', name: 'Catering Orders' },
    //{ id: 'orderTimeChanged', name: 'Order Time Changed' }
  ]),
  notificationChannels: new Enum([
    { id: 'none', name: 'None' },
    { id: 'auto', name: 'Auto Acknowledge' },
    { id: 'phone', name: 'Phone Call' },
    { id: 'fax', name: 'Fax' },
    { id: 'ivr', name: 'Automated Call' },
    { id: 'email', name: 'Email' },
    { id: 'http', name: 'HTTP' },
    { id: 'sms', name: 'SMS' },
    { id: 'gcm', name: 'Android App' },
    { id: 'apns', name: 'iOS App' },
    { id: 'custom', name: 'Custom Module' }
  ]),
  notificationDispatchers: new Enum([
    { id: 'custom', name: 'Custom Recipients' },
    { id: 'orderDeliverer', name: 'Order Deliverer' },
    { id: 'orderDiners', name: 'Order Diners' },
    { id: 'orderEaters', name: 'Order Eaters' },<commit_msg>Added approved/rejected notification events<commit_after>'use strict';

var _ = require('lodash');

function Enum(values) {

  var keys = [];
  var map = {};

  function add(id, name) {
    keys.push(id);
    map[id] = name;
  }

  if (values) {
    values.forEach(function(v) { add(v.id, v.name); });
  }

  return _.extend(map, {
    add: add,
    keys: function() { return keys; }
  });

}

module.exports = exports = {
  cardTypes: new Enum([
    { id: 'none', name: 'None' },
    { id: 'visa', name: 'VISA' },
    { id: 'masterCard', name: 'MasterCard' },
    { id: 'americanExpress', name: 'American Express' },
    { id: 'discover', name: 'Discover' },
    { id: 'dinersClub', name: 'Diners Club' },
    { id: 'jcb', name: 'JCB' },
    { id: 'laser', name: 'Laser' },
    { id: 'maestro', name: 'Maestro' }
  ]),
  cuisineTypes: new Enum([
    { id: 'African', name: 'African' },
    { id: 'American', name: 'American' },
    { id: 'Asian', name: 'Asian' },
    { id: 'Bakery', name: 'Bakery' },
    { id: 'Balkan', name: 'Balkan' },
    { id: 'BBQ', name: 'BBQ' },
    { id: 'Breakfast', name: 'Breakfast' },
    { id: 'British', name: 'British' },
    { id: 'Brunch', name: 'Brunch' },
    { id: 'Burgers', name: 'Burgers' },
    { id: 'Cafe', name: 'Cafe' },
    { id: 'Cantonese', name: 'Cantonese' },
    { id: 'Caribbean', name: 'Caribbean' },
    { id: 'Cheesesteaks', name: 'Cheesesteaks' },
    { id: 'Chicken', name: 'Chicken' },
    { id: 'Chinese', name: 'Chinese' },
    { id: 'Classic', name: 'Classic' },
    { id: 'Cuban', name: 'Cuban' },
    { id: 'Deli', name: 'Deli' },
    { id: 'Dessert', name: 'Dessert' },
    { id: 'Dim Sum', name: 'Dim Sum' },
    { id: 'English', name: 'English' },
    { id: 'Ethiopian', name: 'Ethiopian' },
    { id: 'Food Truck', name: 'Food Truck' },
    { id: 'French', name: 'French' },
    { id: 'Fresh Fruits', name: 'Fresh Fruits' },
    { id: 'Fusion', name: 'Fusion' },
    { id: 'Gluten-Free', name: 'Gluten-Free' },
    { id: 'Grinders', name: 'Grinders' },
    { id: 'Greek', name: 'Greek' },
    { id: 'Halal', name: 'Halal' },
    { id: 'Healthy', name: 'Healthy' },
    { id: 'Indian', name: 'Indian' },
    { id: 'Irish', name: 'Irish' },
    { id: 'Italian', name: 'Italian' },
    { id: 'Jamaican', name: 'Jamaican' },
    { id: 'Japanese', name: 'Japanese' },
    { id: 'Jewish', name: 'Jewish' },
    { id: 'Korean', name: 'Korean' },
    { id: 'Late Night', name: 'Late Night' },
    { id: 'Latin', name: 'Latin' },
    { id: 'Lebanese', name: 'Lebanese' },
    { id: 'Low Carb', name: 'Low Carb' },
    { id: 'Low Fat', name: 'Low Fat' },
    { id: 'Lunch Specials', name: 'Lunch Specials' },
    { id: 'Mandarin', name: 'Mandarin' },
    { id: 'Mediterranean', name: 'Mediterranean' },
    { id: 'Mexican', name: 'Mexican' },
    { id: 'Middle Eastern', name: 'Middle Eastern' },
    { id: 'Moroccan', name: 'Moroccan' },
    { id: 'Noodles', name: 'Noodles' },
    { id: 'Organic', name: 'Organic' },
    { id: 'Pakistani', name: 'Pakistani' },
    { id: 'Peruvian', name: 'Peruvian' },
    { id: 'Pizza', name: 'Pizza' },
    { id: 'Polish', name: 'Polish' },
    { id: 'Puerto Rican', name: 'Puerto Rican' },
    { id: 'Salads', name: 'Salads' },
    { id: 'Sandwiches', name: 'Sandwiches' },
    { id: 'Seafood', name: 'Seafood' },
    { id: 'Soul Food', name: 'Soul Food' },
    { id: 'Soup', name: 'Soup' },
    { id: 'Southern', name: 'Southern' },
    { id: 'Steakhouse', name: 'Steakhouse' },
    { id: 'Subs', name: 'Subs' },
    { id: 'Sushi', name: 'Sushi' },
    { id: 'Swedish', name: 'Swedish' },
    { id: 'Szechwan', name: 'Szechwan' },
    { id: 'Tapas', name: 'Tapas' },
    { id: 'Thai', name: 'Thai' },
    { id: 'Vegan', name: 'Vegan' },
    { id: 'Vegetarian', name: 'Vegetarian' },
    { id: 'Venezuelan', name: 'Venezuelan' },
    { id: 'Vietnamese', name: 'Vietnamese' },
    { id: 'Wings', name: 'Wings' }
  ]),
  day: new Enum([
    { id: 0, name: 'Sunday' },
    { id: 1, name: 'Monday' },
    { id: 2, name: 'Tuesday' },
    { id: 3, name: 'Wednesday' },
    { id: 4, name: 'Thursday' },
    { id: 5, name: 'Friday' },
    { id: 6, name: 'Saturday' }
  ]),
  deliveryTypes: new Enum([
    { id: 'unknown', name: 'unknown' },
    { id: 'delivery', name: 'delivery' },
    { id: 'pickup', name: 'pickup' }
  ]),
  eventTopics: new Enum([
    { id: 'event.orders.order.started', name: 'Order Started' },
    { id: 'event.orders.order.updated', name: 'Order Updated' },
    { id: 'event.orders.order.submitted', name: 'Order Submitted' },
    { id: 'event.orders.order.authorized', name: 'Order Authorized' },
    { id: 'event.orders.order.invoiced', name: 'Order Invoiced' },
    { id: 'event.orders.order.confirmed', name: 'Order Confirmed' },
    { id: 'event.orders.order.settled', name: 'Order Settled' },
    { id: 'event.orders.order.enroute', name: 'Order In Transit' },
    { id: 'event.orders.order.fulfilled', name: 'Order Fulfilled' },
    { id: 'event.orders.order.canceled', name: 'Order Canceled' },
    { id: 'event.orders.order.error', name: 'Order Error' },
    { id: 'event.orders.order.reminder', name: 'Order Reminder' },
    { id: 'event.orders.order.survey', name: 'Order Survey' },
    { id: 'event.orders.part.added', name: 'Diner Added' },
    { id: 'event.orders.part.submitted', name: 'Diner Submitted' },
    { id: 'event.orders.part.removed', name: 'Diner Removed' },
    { id: 'event.orders.part.reminder', name: 'Diner Reminder' },
    { id: 'event.orders.order.transmit', name: 'Ready to Transmit' },
    { id: 'event.orders.order.batchTransmit', name: 'Ready to Transmit (batch)' },
    { id: 'event.orders.order.confirm', name: 'Ready to Confirm' },
    { id: 'event.orders.order.batchVerify', name: 'Ready to Verify (batch)' },
    { id: 'event.orders.order.invite', name: 'Recurring Order Invite' },
    { id: 'event.restaurants.restaurant.verify-email', name: 'Restaurant Onboarding Email' },
    { id: 'event.restaurants.restaurant.verify-fax', name: 'Restaurant Onboarding Fax' },
    { id: 'event.restaurants.restaurant.approved', name: 'Restaurant Onboarding Approved' },
    { id: 'event.restaurants.restaurant.rejected', name: 'Restaurant Onboarding Rejected' },
    { id: 'messages.restaurant.claim', name: 'Restaurant Claimed' },
    { id: 'messages.change.restaurant.claim', name: 'Restaurant Claim Reviewed' },
    { id: 'event.vcn.reconciliation.settled', name: 'VCN Settlement' },
    { id: 'event.vcn.reconciliation.error', name: 'VCN Reconciliation Error' }
  ]),
  eventFilters: new Enum([
    { id: 'groupOrder', name: 'Group Orders' },
    { id: 'individualOrder', name: 'Individual Orders' },
    { id: 'cateringOrder', name: 'Catering Orders' },
    //{ id: 'orderTimeChanged', name: 'Order Time Changed' }
  ]),
  notificationChannels: new Enum([
    { id: 'none', name: 'None' },
    { id: 'auto', name: 'Auto Acknowledge' },
    { id: 'phone', name: 'Phone Call' },
    { id: 'fax', name: 'Fax' },
    { id: 'ivr', name: 'Automated Call' },
    { id: 'email', name: 'Email' },
    { id: 'http', name: 'HTTP' },
    { id: 'sms', name: 'SMS' },
    { id: 'gcm', name: 'Android App' },
    { id: 'apns', name: 'iOS App' },
    { id: 'custom', name: 'Custom Module' }
  ]),
  notificationDispatchers: new Enum([
    { id: 'custom', name: 'Custom Recipients' },
    { id: 'orderDeliverer', name: 'Order Deliverer' },
    { id: 'orderDiners', name: 'Order Diners' },
    { id: 'orderEaters', name: 'Order Eaters' },
{'fraction_non_alphanumeric': 0.21924225964149918, 'fraction_numerical': 0.0009505703422053232, 'mean_word_length': 3.192712781098776, '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': '2519240', 'n_tokens_mistral': 5842, 'n_tokens_neox': 5555, 'n_words': 1407}