Skip to content
This repository has been archived by the owner on Dec 26, 2022. It is now read-only.

Commit

Permalink
fix(core): Return error if transaction not found
Browse files Browse the repository at this point in the history
Return error code if find_transaction_object can't find any result since
default response would be null trytes instead.
  • Loading branch information
Yu Wei Wu committed Mar 18, 2019
1 parent cec1168 commit 70928dd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions accelerator/common_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -389,6 +389,9 @@ status_t ta_get_transaction_object(const iota_client_service_t* const service,
(tryte_t*)cache_value, NUM_TRYTES_SERIALIZED_TRANSACTION, tx_trits,
NUM_TRITS_SERIALIZED_TRANSACTION, NUM_TRITS_SERIALIZED_TRANSACTION);
cache_set(cache, req, cache_value);
} else {
ret = SC_CCLIENT_NOT_FOUND;
goto done;
}
}

Expand Down

0 comments on commit 70928dd

Please sign in to comment.