mirror of
https://github.com/status-im/codex-contracts-eth.git
synced 2025-01-31 02:35:36 +00:00
[marketplace] inline function _notEqual
This commit is contained in:
parent
e496ac3550
commit
bb0302afcb
@ -235,7 +235,7 @@ contract Marketplace is Collateral, Proofs, StateRetrieval {
|
||||
SlotId slotId
|
||||
) internal view returns (RequestId) {
|
||||
Slot memory slot = _slot(slotId);
|
||||
require(_notEqual(slot.requestId, 0), "Missing request id");
|
||||
require(RequestId.unwrap(slot.requestId) != 0, "Missing request id");
|
||||
return slot.requestId;
|
||||
}
|
||||
|
||||
@ -365,10 +365,6 @@ contract Marketplace is Collateral, Proofs, StateRetrieval {
|
||||
return s == RequestState.New || s == RequestState.Started;
|
||||
}
|
||||
|
||||
function _notEqual(RequestId a, uint256 b) internal pure returns (bool) {
|
||||
return RequestId.unwrap(a) != bytes32(b);
|
||||
}
|
||||
|
||||
enum RequestState {
|
||||
New, // [default] waiting to fill slots
|
||||
Started, // all slots filled, accepting regular proofs
|
||||
|
Loading…
x
Reference in New Issue
Block a user