@@ -129,10 +129,10 @@ export default {
129129 // Check if profile uses secure download
130130 if (profile && profile .secureDownload ) {
131131 // Token-based secure download
132- client .post (this .settings .url + ' attachment/download/get-file-token.json ' , { file: attachment .id })
132+ client .post (this .settings .url + ' attachment/download/get-file-token' , { file: attachment .id })
133133 .then ((response ) => {
134134 const token = response .data .token
135- return client .get (this .settings .url + ' attachment/download/file/ ' + token, {responseType: ' arraybuffer' })
135+ return client .get (this .settings .url + ' attachment/download/file?token= ' + token, {responseType: ' arraybuffer' })
136136 })
137137 .then ((response ) => {
138138 this .forceFileDownload (response, attachment)
@@ -160,7 +160,7 @@ export default {
160160
161161 // Fetch token for video/PDF preview
162162 if (attachment .type === ' video' || attachment .subtype === ' pdf' ) {
163- client .post (this .settings .url + ' attachment/download/get-file-token.json ' , { file: attachment .id })
163+ client .post (this .settings .url + ' attachment/download/get-file-token' , { file: attachment .id })
164164 .then ((response ) => {
165165 this .$set (this .previewTokens , attachment .id , response .data .token )
166166 })
@@ -171,7 +171,7 @@ export default {
171171 const profile = this .$store .get (this .aid + ' /settings.profiles.' + attachment .profile )
172172
173173 if (profile && profile .secureDownload && this .previewTokens [attachment .id ]) {
174- return this .settings .url + ' attachment/download/stream/ ' + this .previewTokens [attachment .id ]
174+ return this .settings .url + ' attachment/download/stream?token= ' + this .previewTokens [attachment .id ]
175175 }
176176 return attachment .url
177177 },
0 commit comments