Skip to content

Commit

Permalink
chore: Fix the cache header for current loader (#795)
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickhousley authored Oct 31, 2023
1 parent 1336111 commit 35ae316
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/actions/update-current/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,13 @@ const s3Client = new S3Client({
const results = await Promise.all(
constructLoaderFileNames(args.loaderVersion)
.map(async loader => {
const currentLoaderName = loader.replace(args.loaderVersion, 'current')
const commandOpts = {
Bucket: args.bucket,
CopySource: `${args.bucket}/${loader}`,
Key: loader.replace(args.loaderVersion, 'current'),
ContentType: mime.lookup(loader) || 'application/javascript',
CacheControl: getAssetCacheHeader('/', loader),
Key: currentLoaderName,
ContentType: mime.lookup(currentLoaderName) || 'application/javascript',
CacheControl: getAssetCacheHeader('/', currentLoaderName),
MetadataDirective: 'REPLACE',
TaggingDirective: 'COPY'
}
Expand Down

0 comments on commit 35ae316

Please sign in to comment.