Skip to content

Commit

Permalink
fix: bad key in anomalies
Browse files Browse the repository at this point in the history
  • Loading branch information
TobiTenno committed Mar 23, 2024
1 parent 10b18e7 commit df25d94
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
5 changes: 2 additions & 3 deletions lib/models/SentientOutpost.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,11 @@ const sat = () => {
export default class SentientOutpost {
#node;
constructor(data, { locale, sentientData, logger }) {
// eslint-disable-next-line no-param-reassign
if (!data) data = '{"sfn":000}';
[this.#node] = data.match(/\d{3}/g) || ['000'];
const id = `CrewBattleNode${node}`;
const id = `CrewBattleNode${this.#node}`;
/* istanbul ignore if */
if (node === '000') {
if (this.#node === '000') {
this.mission = undefined;
} else {
this.mission = {
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "warframe-worldstate-parser",
"version": "2.8.0",
"version": "0.0.0-dev",
"description": "An Open parser for Warframe's Worldstate in Javascript",
"types": "./types/main.d.ts",
"main": "main.js",
Expand Down Expand Up @@ -33,7 +33,7 @@
"build:docs": "jsdoc -c jsdoc-config.json -d docs",
"lint": "eslint main.js lib/ test/",
"lint:fix": "eslint main.js lib/ test/ --fix",
"postinstall": "npx -p install-peerdeps@latest install-peerdeps @wfcd/eslint-config@^1.5.0 -S | npx -p [email protected] install-peerdeps @wfcd/eslint-config@^1.5.0 -S",
"postinstall": "npx install-peerdeps @wfcd/eslint-config@latest -S",
"prepublishOnly": "npm run build:types && npm_config_yes=true npx clean-package",
"build:types": "tsc -p tsconfig.declaration.json",
"validate": "exit 0"
Expand Down
3 changes: 2 additions & 1 deletion test/integration/integration.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ describe('WorldState (integration)', () => {
(() => {
try {
// once without kuva data
wsl = new WorldState(ws, { logger, locale: 'en' });
// wsl = new WorldState(ws, { logger, locale: 'en' });
wsl = new WorldState(ws, { logger, locale: 'en', kuvaData });
} catch (e) {
console.error(e); // eslint-disable-line no-console
Expand All @@ -53,6 +53,7 @@ describe('WorldState (integration)', () => {
expect(Ostrons.jobs).to.exist;
expect(Ostrons.jobs).to.be.an('array');
expect(wsl?.fissures).to.exist;
expect(wsl?.sentientOutposts.id).to.not.contain('dataOverride');

/* Easy debugging! */
if (process.env.CI) {
Expand Down

0 comments on commit df25d94

Please sign in to comment.