mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-08-24 16:01:42 +00:00
fix: strip prefix of s3 resource (#2780)
This commit is contained in:
committed by
GitHub
parent
cb8bc75b30
commit
f3a0c81639
@@ -631,15 +631,11 @@ async fn get_workspace_s3_resource<'c>(
|
||||
LargeFileStorage::S3Storage(s3_lfs) => s3_lfs,
|
||||
};
|
||||
|
||||
return get_s3_resource(
|
||||
authed,
|
||||
user_db,
|
||||
db,
|
||||
token,
|
||||
w_id,
|
||||
s3_lfs.s3_resource_path.as_str(),
|
||||
)
|
||||
.await;
|
||||
let stripped_resource_path = match s3_lfs.s3_resource_path.strip_prefix("$res:") {
|
||||
Some(stripped) => stripped,
|
||||
None => s3_lfs.s3_resource_path.as_str(),
|
||||
};
|
||||
return get_s3_resource(authed, user_db, db, token, w_id, stripped_resource_path).await;
|
||||
}
|
||||
|
||||
async fn get_s3_resource<'c>(
|
||||
|
||||
Reference in New Issue
Block a user