From 14520fbce8ae281050f5140b3d16a87cbc06d2c1 Mon Sep 17 00:00:00 2001 From: Mutzi Date: Sun, 12 Jan 2025 14:29:47 +0100 Subject: [PATCH] Fixed download_multi --- frontend/src/store.ts | 2 +- src/main/java/de/mattv/fileserver/FileServerApplication.java | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/frontend/src/store.ts b/frontend/src/store.ts index 74e2244..73e2714 100644 --- a/frontend/src/store.ts +++ b/frontend/src/store.ts @@ -86,7 +86,7 @@ export async function download(nodes: T[]) form.innerHTML += ``; } else { form.action = '/api/public/download_multi'; - form.innerHTML += ``; + form.innerHTML += ``; const resp = await workingWrapper(() => rpc.getNodesSize(nodes.map(v => v.id))); if (!resp) return; diff --git a/src/main/java/de/mattv/fileserver/FileServerApplication.java b/src/main/java/de/mattv/fileserver/FileServerApplication.java index 3ad3bde..7597867 100644 --- a/src/main/java/de/mattv/fileserver/FileServerApplication.java +++ b/src/main/java/de/mattv/fileserver/FileServerApplication.java @@ -9,6 +9,7 @@ import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.http.HttpMessageConverters; import org.springframework.boot.web.servlet.FilterRegistrationBean; import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Profile; import org.springframework.http.HttpOutputMessage; import org.springframework.http.converter.HttpMessageConverter; import org.springframework.http.converter.HttpMessageNotWritableException; @@ -52,6 +53,7 @@ public class FileServerApplication { } @Bean + @Profile("!dev") public FilterRegistrationBean nonApiToIndex() { return new FilterRegistrationBean<>((servletRequest, servletResponse, chain) -> { String uri = ((HttpServletRequest) servletRequest).getRequestURI();