From bf9704865ceed469fe2464f6080e02f4c9e344b6 Mon Sep 17 00:00:00 2001 From: MoonBoi9001 Date: Thu, 3 Oct 2024 11:34:48 +0100 Subject: [PATCH] fix: apply consistent mapping order inside ProvisionManager.sol (OZ_N-05) --- .../contracts/data-service/utilities/ProvisionManager.sol | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/horizon/contracts/data-service/utilities/ProvisionManager.sol b/packages/horizon/contracts/data-service/utilities/ProvisionManager.sol index d1cf94287..51fbb7064 100644 --- a/packages/horizon/contracts/data-service/utilities/ProvisionManager.sol +++ b/packages/horizon/contracts/data-service/utilities/ProvisionManager.sol @@ -71,7 +71,7 @@ abstract contract ProvisionManager is Initializable, GraphDirectory, ProvisionMa * @param caller The address of the caller. * @param serviceProvider The address of the service provider. */ - error ProvisionManagerNotAuthorized(address caller, address serviceProvider); + error ProvisionManagerNotAuthorized(address serviceProvider, address caller); /** * @notice Thrown when a provision is not found. @@ -84,8 +84,8 @@ abstract contract ProvisionManager is Initializable, GraphDirectory, ProvisionMa */ modifier onlyProvisionAuthorized(address serviceProvider) { require( - _graphStaking().isAuthorized(msg.sender, serviceProvider, address(this)), - ProvisionManagerNotAuthorized(msg.sender, serviceProvider) + _graphStaking().isAuthorized(serviceProvider, msg.sender, address(this)), + ProvisionManagerNotAuthorized(serviceProvider, msg.sender) ); _; }