From f154543a09411ab7f8ca6fe698b00fbe7838a9fd Mon Sep 17 00:00:00 2001 From: NanZhang Date: Thu, 16 Nov 2023 11:57:59 +0800 Subject: [PATCH] fix: query cell_output by hex index (#1499) --- app/models/deployed_cell.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/models/deployed_cell.rb b/app/models/deployed_cell.rb index cb325a726..45c3ce6cc 100644 --- a/app/models/deployed_cell.rb +++ b/app/models/deployed_cell.rb @@ -66,8 +66,7 @@ def self.create_initial_data_for_ckb_transaction(ckb_transaction, cell_deps) parse_code_dep = ->(cell_dep) do # this cell output is the contract cell, i.e. one of deployed cells of the contract - cell_output = CellOutput.find_by tx_hash: cell_dep["out_point"]["tx_hash"], - cell_index: cell_dep["out_point"]["index"] + cell_output = CellOutput.find_by_pointer cell_dep["out_point"]["tx_hash"], cell_dep["out_point"]["index"] attr = { contract_cell_id: cell_output.id,