HydraDX-node
HydraDX-node copied to clipboard
Remove route signature redundancy and add new features to router
In router sell and buy the user needs to specify the trades of the route: https://github.com/galacticcouncil/HydraDX-node/blob/8abf856afa839b798c4e39e38af2b2901f55739b/pallets/route-executor/src/lib.rs#L187
This contains duplicated data as the asset out is always the next trade asset in. By simplifying the signature, we could simplify the validation we have in the code regarding.
As we don't want to break APIs, we could only solve this by introducing a new sell and buy extrinsics. Once we do it, we could also add new features for router which are still open for discussions.