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

Shouldn't check wallet before requests that doesn't require wallet. #928

Open
devyetii opened this issue Apr 29, 2023 · 0 comments
Open

Comments

@devyetii
Copy link
Collaborator

Most of GET requests in zcncore like this one:

gosdk/zcncore/wallet_base.go

Lines 1006 to 1017 in f0d0889

// GetAllocation obtains allocation information.
func GetAllocation(allocID string, cb GetInfoCallback) (err error) {
if err = CheckConfig(); err != nil {
return
}
var url = withParams(STORAGESC_GET_ALLOCATION, Params{
"allocation": allocID,
})
go GetInfoFromSharders(url, OpStorageSCGetAllocation, cb)
return
}

checks for valid wallet, however the wallet is not needed for such a request, should only check sdk config. This affect 0box, for example, since no wallet is configured for it usually.

Related discussion: https://0chain.slack.com/archives/C04EFTQH26T/p1682726300357019

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

No branches or pull requests

2 participants