@social-mail/social-mail-web-server 1.7.7 → 1.7.8
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/dist/server/services/image-converter/ImageConverterService.d.ts.map +1 -1
- package/dist/server/services/image-converter/ImageConverterService.js +4 -1
- package/dist/server/services/image-converter/ImageConverterService.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/server/services/image-converter/ImageConverterService.ts +5 -1
package/package.json
CHANGED
|
@@ -130,13 +130,17 @@ export default class ImageConverterService {
|
|
|
130
130
|
|
|
131
131
|
const tf = await this.tempFileService.createTempFile(ext, outputFileName);
|
|
132
132
|
|
|
133
|
-
await IsolatedProcess.convertImage({
|
|
133
|
+
const result = await IsolatedProcess.convertImage({
|
|
134
134
|
type,
|
|
135
135
|
input: { path: file.path },
|
|
136
136
|
output: { path: tf.path },
|
|
137
137
|
outputFileName
|
|
138
138
|
});
|
|
139
139
|
|
|
140
|
+
if (tf.isEmpty || result.status !== 0) {
|
|
141
|
+
throw new Error(`Image conversion failed from ${file.path} to ${tf.path} ${result.all}`);
|
|
142
|
+
}
|
|
143
|
+
|
|
140
144
|
return tf;
|
|
141
145
|
}
|
|
142
146
|
|