[client] Use stat to check whether deps are directories
[client] Use stat to check whether deps are directories

The purpose of making this CL is just to help me take a look at
part of this codebase. This would resolve a minor TODO left by djd
and simplify the code slightly.

Change-Id: I1ca0397e60b13cfc82f44730515685362751722b
Reviewed-on: https://chromium-review.googlesource.com/c/1453021
Commit-Queue: Quinten Yearsley <747cf52e0cef2e3e9371802a2d344b6c87126a4b@chromium.org>
Reviewed-by: Marc-Antoine Ruel <d2bf0fc09b08f7b0888b3ddab32b3e89c7122c8b@chromium.org>

luci/luci-go,luci/luci-go,luci/luci-go,luci/luci-go,luci/luci-go,luci/luci-go