Apply suggestions from code review
Co-authored-by: str4d <thestr4d@gmail.com>
This commit is contained in:
parent
6a7cfdea54
commit
dc9c95b705
|
@ -875,14 +875,13 @@ bool CWallet::Verify()
|
|||
|
||||
if (walletFile != boost::filesystem::basename(walletFile) + boost::filesystem::extension(walletFile)) {
|
||||
boost::filesystem::path path(walletFile);
|
||||
if(path.is_absolute()) {
|
||||
if (path.is_absolute()) {
|
||||
if (!boost::filesystem::exists(path.parent_path())) {
|
||||
return UIError(strprintf(_("Absolute path %s do not exist"), walletFile));
|
||||
}
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
boost::filesystem::path full_path = GetDataDir() / path;
|
||||
if(!boost::filesystem::exists(full_path.parent_path())) {
|
||||
if (!boost::filesystem::exists(full_path.parent_path())) {
|
||||
return UIError(strprintf(_("Relative path %s do not exist"), walletFile));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue