Skip to content

Commit

Permalink
minor tweaks ✅; 3.0.0-alpha.1
Browse files Browse the repository at this point in the history
  • Loading branch information
derhuerst committed Mar 4, 2024
1 parent c55b610 commit 187726c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@derhuerst/stable-public-transport-ids",
"description": "Get stable IDs for public transport stations, etc.",
"version": "2.1.0",
"version": "3.0.0-alpha.1",
"type": "module",
"dataVersion": 2,
"main": "index.js",
Expand Down
1 change: 1 addition & 0 deletions stop.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ const createGetStableStopIds = (dataSource, normalizeName) => {

const stableIds = [
// third-party IDs
// todo: lower-case?
s.wikidataId ? [s.wikidataId, baseSpecificity + 10] : null,
s.osmId ? [s.osmId, baseSpecificity + 10] : null,

Expand Down
1 change: 1 addition & 0 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ test('operator OneStop ID', (t) => {

const beginsWith = str => ([str2]) => str2.slice(0, str.length) === str
const onestopId = ids.find(beginsWith(`${v}:custom:o:`))
t.ok(onestopId)
t.deepEqual(ids, [
[[v, op.wikidataId].join(':'), 10],
[[v, 'sauce', op.id].join(':'), 20],
Expand Down

0 comments on commit 187726c

Please sign in to comment.