Skip to content

Commit

Permalink
safe
Browse files Browse the repository at this point in the history
  • Loading branch information
Skydev0h committed Dec 26, 2023
1 parent 935a152 commit f52593f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion contracts/task3.fc
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ cell migrate_one(cell old_storage) { return old_storage; }
cell storage = ds.preload_ref();

if (expected_version != version) {
;; throw_if(200, expected_code.null?());
throw_if(200, expected_code.null?());

while (version != expected_version) {
(slice mig, int found) = migrations.udict_get?(32, version);
Expand All @@ -76,6 +76,12 @@ cell migrate_one(cell old_storage) { return old_storage; }

set_c3(expected_code.begin_parse().bless());
set_code(expected_code);
set_data(begin_cell()
.store_uint(version, 32)
.store_ref(storage)
.end_cell()
);
commit();
}

storage = process_message(storage, msg_value, balance, in_msg_full, payload.begin_parse());
Expand Down

0 comments on commit f52593f

Please sign in to comment.