Correctly check if a directory exists
Test: Run unit test cases
Change-Id: I61a50450afd638da646e16e07cfdf800d4975d13
diff --git a/hardware_android.cc b/hardware_android.cc
index ac6cf16..0bf05e4 100644
--- a/hardware_android.cc
+++ b/hardware_android.cc
@@ -181,7 +181,7 @@
bool HardwareAndroid::GetNonVolatileDirectory(base::FilePath* path) const {
base::FilePath local_path(constants::kNonVolatileDirectory);
- if (!base::PathExists(local_path)) {
+ if (!base::DirectoryExists(local_path)) {
LOG(ERROR) << "Non-volatile directory not found: " << local_path.value();
return false;
}