Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

oversmash

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

oversmash - npm Package Compare versions

Comparing version 1.2.5 to 1.3.2

CHANGELOG.md

16

build/index.js

@@ -11,3 +11,10 @@ 'use strict';

var _ref = _asyncToGenerator(function* (req, options, name) {
const searchPath = (0, _urlJoin2.default)('/search/account-by-name', name);
// Turn the last dash into a URL-encoded pound sign, so we can get
// a positive match including the account ID
const nameEscaped = name.replace(/-(\d+)$/, '%23$1'); // # == %23
// Note that the pound sign here is ignored, we keep it in just to make
// debug logs clearer, and because it doesn't cause any harm:
const searchPath = (0, _urlJoin2.default)('/search/account-by-name', nameEscaped);
log('findPlayer/http get', searchPath);

@@ -20,2 +27,3 @@

const accounts = response.map(function (account) {
console.log(account);
const accountIdentity = account.careerLink.match(options.accountIdentityRegex);

@@ -31,4 +39,3 @@

displayName: account.platformDisplayName,
platform: accountIdentity[1],
region: accountIdentity[2]
platform: accountIdentity[1]
};

@@ -103,3 +110,4 @@ });

defaultPlatform: 'pc',
accountIdentityRegex: /^\/career\/([\w]+)\/([\w]+)\/.+$/,
accountIdentityRegex: /^\/career\/([\w]+)\/.+$/,
strictPlayerSearch: true,
requestOptions: {

@@ -106,0 +114,0 @@ baseUrl: 'https://playoverwatch.com/en-us',

@@ -187,3 +187,3 @@ 'use strict';

log('scrape', careerType, heroName);
log('scrape', careerType, heroName, heroStats[heroName]);
});

@@ -190,0 +190,0 @@

{
"name": "oversmash",
"version": "1.2.5",
"version": "1.3.2",
"license": "MIT",

@@ -5,0 +5,0 @@ "homepage": "https://github.com/filp/oversmash",

@@ -9,2 +9,4 @@ # oversmash [![npm version](https://badge.fury.io/js/oversmash.svg)](https://badge.fury.io/js/oversmash)

**Note: See [CHANGELOG.MD](/CHANGELOG.md) for change details**
## Features

@@ -40,3 +42,4 @@

// Get basic details about a user, including their platform/region accounts
// Get basic details about a user, including their platform/region accounts.
//
ow.player('bob-12345').then(player => {

@@ -52,4 +55,3 @@ console.log(player)

// displayName: 'bob#12345',
// platform: 'pc',
// region: 'eu' } ] }
// platform: 'pc' } ] }

@@ -121,2 +123,3 @@ // Get detailed stats about a user (for a specific region), including

accountIdentityRegex: /^\/career\/([\w]+)\/([\w]+)\/.+$/,
requestOptions: {

@@ -123,0 +126,0 @@ baseURL: 'https://playoverwatch.com/en-us',

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc