From 42344eaa69d56ae8db12d7f06b33d70549280698 Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Thu, 14 Mar 2024 10:03:19 +0300 Subject: [PATCH] [#83] container: Remove outdated migration code Signed-off-by: Evgenii Stratonikov --- container/container_contract.go | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/container/container_contract.go b/container/container_contract.go index e19f8fa..7946923 100644 --- a/container/container_contract.go +++ b/container/container_contract.go @@ -94,26 +94,6 @@ func _deploy(data any, isUpdate bool) { if isUpdate { args := data.([]any) common.CheckVersion(args[len(args)-1].(int)) - - it := storage.Find(ctx, []byte{}, storage.None) - for iterator.Next(it) { - item := iterator.Value(it).(struct { - key []byte - value []byte - }) - - // Migrate container. - if len(item.key) == containerIDSize { - storage.Delete(ctx, item.key) - storage.Put(ctx, append([]byte{containerKeyPrefix}, item.key...), item.value) - } - - // Migrate owner-cid map. - if len(item.key) == 25 /* owner id size */ +containerIDSize { - storage.Delete(ctx, item.key) - storage.Put(ctx, append([]byte{ownerKeyPrefix}, item.key...), item.value) - } - } return } -- 2.45.2