Skip to content
This repository has been archived by the owner on Dec 16, 2024. It is now read-only.

Commit

Permalink
remove publishedLists property
Browse files Browse the repository at this point in the history
  • Loading branch information
andaryjo committed Nov 21, 2023
1 parent f0540e1 commit da3f081
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
6 changes: 0 additions & 6 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ module.exports.fetchData = (uid) => {
roadsAdded: getRoadsAdded(raw),
factsChecked: getFactsChecked(raw),
qa: getQA(raw),
publishedLists: getPublishedLists(raw),
photoViews: getPhotoViews(raw)
}

Expand Down Expand Up @@ -100,11 +99,6 @@ function getQA(raw) {
return parseNumber(extractMatch(raw, pattern));
}

function getPublishedLists(raw) {
let pattern = /(\d+(?:[\.\,]\d+)*) published list[s]?/g;
return parseNumber(extractMatch(raw, pattern));
}

function getPhotoViews(raw) {
const pattern = /[null|"],((?!(?:1,))\d+),\[\[/g;
return parseNumber(extractMatch(raw, pattern));
Expand Down
6 changes: 0 additions & 6 deletions test/client.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,6 @@ describe("Test client", () => {
expect(data).toHaveProperty("qa");
expect(typeof data.qa).toBe("number");

expect(data).toHaveProperty("publishedLists");
expect(typeof data.publishedLists).toBe("number");

expect(data).toHaveProperty("photoViews");
expect(data.photoViews == null || typeof data.photoViews == "number").toBeTruthy();
})
Expand Down Expand Up @@ -90,9 +87,6 @@ describe("Test client", () => {
expect(data).toHaveProperty("qa");
expect(data.qa).toBeNull();

expect(data).toHaveProperty("publishedLists");
expect(data.publishedLists).toBeNull();

expect(data).toHaveProperty("photoViews");
expect(data.photoViews).toBeNull();

Expand Down

0 comments on commit da3f081

Please sign in to comment.