osrs-json-hiscores 2.10.0 → 2.10.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. package/lib/hiscores.js +2 -2
  2. package/package.json +1 -1
package/lib/hiscores.js CHANGED
@@ -186,7 +186,7 @@ function getStats(rsn) {
186
186
  if (typeof rsn !== 'string') {
187
187
  throw Error('RSN must be a string');
188
188
  }
189
- else if (!/^[a-zA-Z0-9 _]+$/.test(rsn)) {
189
+ else if (!/^[a-zA-Z0-9 _-]+$/.test(rsn)) {
190
190
  throw Error('RSN contains invalid character');
191
191
  }
192
192
  else if (rsn.length > 12 || rsn.length < 1) {
@@ -271,7 +271,7 @@ function getStatsByGamemode(rsn, mode) {
271
271
  if (typeof rsn !== 'string') {
272
272
  throw Error('RSN must be a string');
273
273
  }
274
- else if (!/^[a-zA-Z0-9 _]+$/.test(rsn)) {
274
+ else if (!/^[a-zA-Z0-9 _-]+$/.test(rsn)) {
275
275
  throw Error('RSN contains invalid character');
276
276
  }
277
277
  else if (rsn.length > 12 || rsn.length < 1) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "osrs-json-hiscores",
3
- "version": "2.10.0",
3
+ "version": "2.10.1",
4
4
  "description": "The Old School Runescape API wrapper that does more!",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",