Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DatabaseTokenSelection applies predicate in wrong place #248

Open
countfloyd opened this issue Jul 31, 2023 · 0 comments
Open

DatabaseTokenSelection applies predicate in wrong place #248

countfloyd opened this issue Jul 31, 2023 · 0 comments

Comments

@countfloyd
Copy link

In the selectTokens method of DatabaseTokenSelection, the predicate in TokenQueryBy is applied after all of the tokens have been selected that fulfill the required amount (lines 178-181). As a result, when using a predicate, the list of fungible tokens may not satisfy the required amount.

https://github.com/corda/token-sdk/blob/6e2877f08bef55b2544b31c340834ccfaf8463c3/modules/selection/src/main/kotlin/com.r3.corda.lib.tokens.selection/database/selector/DatabaseTokenSelection.kt#L178C6-L182C28

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant