mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
fix: preferCSSPageSize error type (#38761)
fix: preferCSSPageSize error type
This commit is contained in:
@@ -317,7 +317,7 @@ WebContents.prototype.printToPDF = async function (options) {
|
||||
|
||||
if (options.preferCSSPageSize !== undefined) {
|
||||
if (typeof options.preferCSSPageSize !== 'boolean') {
|
||||
return Promise.reject(new Error('footerTemplate must be a String'));
|
||||
return Promise.reject(new Error('preferCSSPageSize must be a Boolean'));
|
||||
}
|
||||
printSettings.preferCSSPageSize = options.preferCSSPageSize;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user