Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

transfer acceleration (#371)

Brendan Allan3f814fd8bc46
diff --git a/apps/web/app/api/upload/signed/route.ts b/apps/web/app/api/upload/signed/route.ts
index ecf39b81c..3bbf512c8 100644
--- a/apps/web/app/api/upload/signed/route.ts
+++ b/apps/web/app/api/upload/signed/route.ts
@@ -145,7 +145,12 @@ export async function POST(request: NextRequest) {
);
// When not using aws s3, we need to transform the url to the local endpoint
- if (clientEnv.NEXT_PUBLIC_CAP_AWS_ENDPOINT) {
+ if (
+ clientEnv.NEXT_PUBLIC_CAP_AWS_BUCKET_URL &&
+ !clientEnv.NEXT_PUBLIC_CAP_AWS_ENDPOINT?.endsWith(
+ "s3-accelerate.amazonaws.com"
+ )
+ ) {
const endpoint = clientEnv.NEXT_PUBLIC_CAP_AWS_ENDPOINT;
const bucket = clientEnv.NEXT_PUBLIC_CAP_AWS_BUCKET;
const newUrl = `${endpoint}/${bucket}/`;
diff --git a/apps/web/utils/s3.ts b/apps/web/utils/s3.ts
index 0a4a6743f..1dbb3136a 100644
--- a/apps/web/utils/s3.ts
+++ b/apps/web/utils/s3.ts
@@ -33,7 +33,6 @@ export async function getS3Config(config?: S3Config) {
accessKeyId: serverEnv.CAP_AWS_ACCESS_KEY ?? "",
secretAccessKey: serverEnv.CAP_AWS_SECRET_KEY ?? "",
},
- forcePathStyle: true,
};
}
diff --git a/crates/media/src/sources/audio_mixer.rs b/crates/media/src/sources/audio_mixer.rs
index 2206c1d95..440e15861 100644
--- a/crates/media/src/sources/audio_mixer.rs
+++ b/crates/media/src/sources/audio_mixer.rs
@@ -136,7 +136,7 @@ impl AudioMixer {
}
while abuffersink.sink().frame(&mut filtered).is_ok() {
- if self.output.send(dbg!(filtered)).is_err() {
+ if self.output.send(filtered).is_err() {
warn!("Mixer unable to send output");
return;
}