mirror of
https://github.com/marcogll/passkit-generator.git
synced 2026-03-16 06:26:09 +00:00
Added check on boardingPass in examples to not make crash the request if we are creating a boarding pass
This commit is contained in:
@@ -143,6 +143,11 @@ export async function* createPassGenerator(
|
||||
);
|
||||
}
|
||||
|
||||
if (pass.type === "boardingPass" && !pass.transitType) {
|
||||
// Just to not make crash the creation if we use a boardingPass
|
||||
pass.transitType = "PKTransitTypeAir";
|
||||
}
|
||||
|
||||
pass = yield pass;
|
||||
|
||||
const buffer = pass.getAsBuffer();
|
||||
|
||||
Reference in New Issue
Block a user