@galadrim/galadmin 0.1.226 → 0.1.228

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/index.ts CHANGED
@@ -194,7 +194,8 @@ export default (config: Config): any => {
194
194
 
195
195
  // Send media files just like they are
196
196
  if ([".woff", ".png"].includes(path.extname(filePath))) {
197
- res.sendFile(filePath)
197
+ res.contentType(mime.getType(filePath));
198
+ res.send(fs.readFileSync(filePath))
198
199
  } else {
199
200
  // For text files, we replace _HOMEPAGE_ with the base url of the back-office
200
201
  let fileContent = fs.readFileSync(filePath, { encoding: "utf-8" })
@@ -155,6 +155,12 @@ export type FileUploadProperties = {
155
155
  region?: string;
156
156
  pathTransform?: (path: string) => string;
157
157
  };
158
+ gcpConfig?: {
159
+ host: string;
160
+ bucket: string;
161
+ subfolder?: string;
162
+ pathTransform?: (path: string) => string;
163
+ };
158
164
  sftpConfig?: {
159
165
  host: string;
160
166
  user: string;