mirror of
https://github.com/marcogll/passkit-generator.git
synced 2026-03-15 18:25:24 +00:00
Introduced check for pass.strings buffer length - will be added if greater than 0
This commit is contained in:
5
index.js
5
index.js
@@ -72,8 +72,11 @@ class Pass {
|
|||||||
|
|
||||||
return Promise.all([...bundle.map(f => readFile(path.resolve(this.model, f))), _passExtractor()]).then(buffers => {
|
return Promise.all([...bundle.map(f => readFile(path.resolve(this.model, f))), _passExtractor()]).then(buffers => {
|
||||||
Object.keys(this.l10n).forEach(l => {
|
Object.keys(this.l10n).forEach(l => {
|
||||||
buffers.push(this._generateStringFile(l));
|
const strings = this._generateStringFile(l);
|
||||||
|
if (strings.length) {
|
||||||
|
buffers.push(strings);
|
||||||
bundle.push(path.join(`${l}.lproj`, `pass.strings`));
|
bundle.push(path.join(`${l}.lproj`, `pass.strings`));
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
return [buffers, bundle];
|
return [buffers, bundle];
|
||||||
|
|||||||
Reference in New Issue
Block a user