Hardcoded value for validAfter argument could prevent users from initiating a subscription at a later time
validAfter is hardcoded to block.timestamp in registerSubscription, blocking users from scheduling a subscription that should start at a chosen future time.
Description
In the registerSubscription() function the validAfter parameter is hardcoded to block.timestamp, which would not allow a user to create a subscription, starting at a certain time in the future.
function registerSubscription(address _subscriber,uint256 _amount,uint256 _validUntil,uint256 _paymentInterval,address _erc20Token) public {require(_amount > 0, "Subscription amount is 0");require(_paymentInterval > 0, "Payment interval is 0");require(msg.sender == _subscriber, "Only the subscriber can register a subscription");ISubExecutor.SubStorage memory sub = ISubExecutor.SubStorage({amount: _amount,validUntil: _validUntil,validAfter: block.timestamp,paymentInterval: _paymentInterval,subscriber: _subscriber,initiator: address(this),erc20TokensValid: _erc20Token == address(0) ? false : true,erc20Token: _erc20Token});}
Impact
Users cannot schedule a subscription to start later than the current block, removing useful scheduling functionality and forcing same-block activation only.
Recommendation
Consider introducing an input argument called _validAfter and passing it for validAfter, including a check that the input value is larger or equal to the block.timestamp:
function registerSubscription(address _subscriber,uint256 _amount,uint256 _validUntil,+ uint256 _validAfter,uint256 _paymentInterval,address _erc20Token) public {+ require(_validAfter >= block.timestamp, "Sub cannot be valid after a time in the past")- validAfter: block.timestamp,+ validAfter: _validAfter,
Resolution
Team Response: Acknowledged and fixed as suggested.

