mirror of
https://github.com/optilude/xlsx-template.git
synced 2026-07-02 00:17:39 +08:00
Revert dynamic file extension detection to hardcoded 'jpg' (#218)
This commit is contained in:
+6
-1
@@ -1454,7 +1454,12 @@ class Workbook {
|
||||
}
|
||||
this.initRichData();
|
||||
const maxFildId = this.findMaxFileId(/xl\/media\/image\d*\..*/, /image(\d*)\./);
|
||||
const fileExtension = substitution.split('.').pop();
|
||||
/**
|
||||
* Setting extension back to "jpg" which works for all image formats
|
||||
* for now. Proper extension detection will be addressed in a future PR
|
||||
* with appropriate testing.
|
||||
*/
|
||||
const fileExtension = "jpg";
|
||||
try {
|
||||
substitution = this.imageToBuffer(substitution);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user