However, these values might be updated in the fee distributor contract (functions setLPStakingAddress, setInventoryStakingAddress) or even the fee distributor itself can change (setFeeDistributor). Now you will need to deploy new Zap contracts if any of these values change.
While I am not sure about the intentions, I wanted to point out this potential issue, and you can clarify if that's an issue or intended behavior.
Recommended Mitigation Steps
To fix this it would increase gas costs but you should query an up to date values whenever you need them.
Handle
pauliax
Vulnerability details
Impact
NFTXMarketplaceZap and NFTXStakingZap cache addresses of lpStaking and inventoryStaking in the constructor:
However, these values might be updated in the fee distributor contract (functions setLPStakingAddress, setInventoryStakingAddress) or even the fee distributor itself can change (setFeeDistributor). Now you will need to deploy new Zap contracts if any of these values change.
While I am not sure about the intentions, I wanted to point out this potential issue, and you can clarify if that's an issue or intended behavior.
Recommended Mitigation Steps
To fix this it would increase gas costs but you should query an up to date values whenever you need them.