mirror of
https://github.com/Llewellynvdm/nativefier.git
synced 2025-02-10 23:18:28 +00:00
Remove all non-ascii characters or use default for app name (#217)
This commit is contained in:
parent
a407b9ea52
commit
48f0872ee5
@ -155,8 +155,8 @@ function optionsFactory(inpOptions, callback) {
|
|||||||
|
|
||||||
function sanitizeFilename(str) {
|
function sanitizeFilename(str) {
|
||||||
const cleaned = sanitizeFilenameLib(str);
|
const cleaned = sanitizeFilenameLib(str);
|
||||||
// remove non ascii
|
// remove all non ascii or use default app name
|
||||||
return cleaned.replace(/[^\x00-\x7F]/, '');
|
return cleaned.replace(/[^\x00-\x7F]/g, '') || DEFAULT_APP_NAME;
|
||||||
}
|
}
|
||||||
|
|
||||||
function sanitizeOptions(options) {
|
function sanitizeOptions(options) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user