From 51029e7e943058d966ca78fcb8bf4abe6014fead Mon Sep 17 00:00:00 2001 From: Ali Naqvi Date: Fri, 12 Dec 2025 11:28:06 +0800 Subject: [PATCH] refactor(loader): [PPT-2328] root_path attribute to retrive folder contents --- shard.lock | 2 +- src/placeos-frontend-loader/loader.cr | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/shard.lock b/shard.lock index 2efa030..2801648 100644 --- a/shard.lock +++ b/shard.lock @@ -79,7 +79,7 @@ shards: git-repository: git: https://github.com/place-labs/git-repository.git - version: 1.7.0 + version: 1.7.1 google: git: https://github.com/placeos/google.git diff --git a/src/placeos-frontend-loader/loader.cr b/src/placeos-frontend-loader/loader.cr index 704e526..54ffd3f 100644 --- a/src/placeos-frontend-loader/loader.cr +++ b/src/placeos-frontend-loader/loader.cr @@ -306,8 +306,8 @@ module PlaceOS::FrontendLoader Log.trace { "#{repository.folder_name}: downloading new content" } commit_ref = repository.commit_hash == "HEAD" ? repository.branch : repository.commit_hash commit = if (root = repository.root_path) && !root.blank? - Log.trace { "Fetching folder as root_path property is set: '#{root}', size: #{root.size}" } - cache.fetch_folder(commit_ref, root, repository_directory) + Log.trace { "Fetching folder contents as root_path property is set: '#{root}', size: #{root.size}" } + cache.fetch_folder_contents(commit_ref, root, repository_directory) else Log.trace { {message: "Fetching commit", commit_ref: commit_ref, repo_dir: repository_directory} } cache.fetch_commit(commit_ref, repository_directory)