We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8a19b3b commit b5bcbd8Copy full SHA for b5bcbd8
src/index.js
@@ -293,11 +293,12 @@ class IpfsRepo {
293
294
const currentRepoVersion = await this.version.get()
295
log(currentRepoVersion)
296
- if (currentRepoVersion >= toVersion) {
297
- if (currentRepoVersion > toVersion) {
298
- log('Your repo\'s version is higher then this version of js-ipfs-repo require! You should revert it.')
299
- }
300
+ if (currentRepoVersion > toVersion) {
+ throw new ERRORS.InvalidRepoVersionError('Your repo\'s version is higher then this version of js-ipfs-repo require! You have to revert it.')
+ }
+
301
+ if (currentRepoVersion === toVersion) {
302
log('Nothing to migrate')
303
return
304
}
0 commit comments