Skip to content

Commit 88a1403

Browse files
rename version to firstPromiseBasedVersion
1 parent 5c81bba commit 88a1403

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

src/registry/domain/storage-adapter.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,12 @@ type LegacyStorageAdapter = {
1313
};
1414

1515
const officialAdapters = {
16-
s3: { name: 'oc-s3-storage-adapter', version: '1.2.0' },
17-
gs: { name: 'oc-gs-storage-adapter', version: '1.1.0' },
18-
'azure-blob-storage': { name: 'oc-azure-storage-adapter', version: '0.1.0' }
16+
s3: { name: 'oc-s3-storage-adapter', firstPromiseBasedVersion: '1.2.0' },
17+
gs: { name: 'oc-gs-storage-adapter', firstPromiseBasedVersion: '1.1.0' },
18+
'azure-blob-storage': {
19+
name: 'oc-azure-storage-adapter',
20+
firstPromiseBasedVersion: '0.1.0'
21+
}
1922
};
2023
type OfficialAdapter = keyof typeof officialAdapters;
2124

@@ -65,7 +68,7 @@ export default function getPromiseBasedAdapter(
6568
if (isOfficialAdapter(adapter)) {
6669
const pkg = officialAdapters[adapter.adapterType];
6770
process.emitWarning(
68-
`Adapters now should work with promises. Consider upgrading your package ${pkg.name} to at least version ${pkg.version}`,
71+
`Adapters now should work with promises. Consider upgrading your package ${pkg.name} to at least version ${pkg.firstPromiseBasedVersion}`,
6972
'DeprecationWarning'
7073
);
7174
} else {

0 commit comments

Comments
 (0)