Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
edolstra committed Feb 12, 2025
1 parent 428a3e8 commit a902b84
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/libfetchers/git-lfs-fetch.cc
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ static std::string getLfsApiToken(const ParsedURL & url)
if (output.empty())
throw Error(
"git-lfs-authenticate: no output (cmd: ssh %s git-lfs-authenticate %s download)",
url.authority.value_or(""), url.path);
url.authority.value_or(""),
url.path);

auto queryResp = nlohmann::json::parse(output);
if (!queryResp.contains("header"))
Expand Down Expand Up @@ -237,8 +238,8 @@ void Fetch::fetch(
}

Path cacheDir = getCacheDir() + "/git-lfs";
std::string key =
hashString(HashAlgorithm::SHA256, pointerFilePath.rel()).to_string(HashFormat::Base16, false) + "/" + pointer->oid;
std::string key = hashString(HashAlgorithm::SHA256, pointerFilePath.rel()).to_string(HashFormat::Base16, false)
+ "/" + pointer->oid;
Path cachePath = cacheDir + "/" + key;
if (pathExists(cachePath)) {
debug("using cache entry %s -> %s", key, cachePath);
Expand Down

0 comments on commit a902b84

Please sign in to comment.