diff --git a/changelog.md b/changelog.md index 78079fa..0f73e9c 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,11 @@ # Changelog +## 2024-12-31 - 1.1.2 - fix(GermanBusinessData) +Ensure unique ID generation for BusinessRecord + +- Added generation of a new ID for each BusinessRecord in GermanBusinessData. +- Ensures each business record has a unique identifier. + ## 2024-12-31 - 1.1.1 - fix(dependencies) Update dependencies and devDependencies to newer versions. diff --git a/ts/00_commitinfo_data.ts b/ts/00_commitinfo_data.ts index 33f719b..f2aa82b 100644 --- a/ts/00_commitinfo_data.ts +++ b/ts/00_commitinfo_data.ts @@ -3,6 +3,6 @@ */ export const commitinfo = { name: '@fin.cx/opendata', - version: '1.1.1', + version: '1.1.2', description: 'A TypeScript-based library for accessing and managing open business data, specifically for German companies.' } diff --git a/ts/classes.germanbusinessdata.ts b/ts/classes.germanbusinessdata.ts index faab9cf..8883599 100644 --- a/ts/classes.germanbusinessdata.ts +++ b/ts/classes.germanbusinessdata.ts @@ -57,6 +57,7 @@ export class GermanBusinessData { totalRecordsCounter++; if (totalRecordsCounter % 10000 === 0) console.log(`${totalRecordsCounter} total records.`); const businessRecord = new this.openDataRef.CBusinessRecord(); + businessRecord.id = await this.openDataRef.CBusinessRecord.getNewId(); businessRecord.data.name = entry.name; await businessRecord.save(); // console.log(`stored ${businessRecord.data.name}`);