@@ -155,75 +155,6 @@ impl DeployedContract {
155155 . map_err ( |e| anyhow:: anyhow!( "contract call `{method}` failed: {e}" ) )
156156 }
157157
158- pub async fn call_from (
159- & self ,
160- client : & NearKitCaller ,
161- method : & str ,
162- args : serde_json:: Value ,
163- ) -> anyhow:: Result < FinalExecutionOutcome > {
164- client
165- . inner
166- . call ( & self . contract_id , method)
167- . args ( args)
168- . gas ( MAX_GAS )
169- . send ( )
170- . await
171- . map_err ( |e| anyhow:: anyhow!( "contract call `{method}` (external signer) failed: {e}" ) )
172- }
173-
174- pub async fn call_from_with_deposit (
175- & self ,
176- client : & NearKitCaller ,
177- method : & str ,
178- args : serde_json:: Value ,
179- gas : near_kit:: Gas ,
180- deposit : near_kit:: NearToken ,
181- ) -> anyhow:: Result < FinalExecutionOutcome > {
182- client
183- . inner
184- . call ( & self . contract_id , method)
185- . args ( args)
186- . gas ( gas)
187- . deposit ( deposit)
188- . send ( )
189- . await
190- . map_err ( |e| anyhow:: anyhow!( "contract call `{method}` (with deposit) failed: {e}" ) )
191- }
192-
193- /// Like [`Self::call_from`], but with an attached `deposit`.
194- pub async fn call_from_deposit (
195- & self ,
196- client : & NearKitCaller ,
197- method : & str ,
198- args : serde_json:: Value ,
199- deposit : near_kit:: NearToken ,
200- ) -> anyhow:: Result < FinalExecutionOutcome > {
201- self . call_from_with_deposit ( client, method, args, MAX_GAS , deposit)
202- . await
203- }
204-
205- /// Call a method whose arguments are borsh-serialized (e.g. `propose_update`).
206- pub async fn call_from_borsh_with_deposit < A : borsh:: BorshSerialize > (
207- & self ,
208- client : & NearKitCaller ,
209- method : & str ,
210- args : A ,
211- gas : near_kit:: Gas ,
212- deposit : near_kit:: NearToken ,
213- ) -> anyhow:: Result < FinalExecutionOutcome > {
214- client
215- . inner
216- . call ( & self . contract_id , method)
217- . args_borsh ( args)
218- . gas ( gas)
219- . deposit ( deposit)
220- . send ( )
221- . await
222- . map_err ( |e| {
223- anyhow:: anyhow!( "contract call `{method}` (borsh args, with deposit) failed: {e}" )
224- } )
225- }
226-
227158 pub async fn view < T : DeserializeOwned + Send + ' static > (
228159 & self ,
229160 method : & str ,
0 commit comments