We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f1ddf15 commit 62888b8Copy full SHA for 62888b8
index.js
@@ -76,8 +76,9 @@ export class TopBun {
76
* @param {CurrentOpts} [opts] - The options for the site build
77
*/
78
constructor (src, dest, opts = /** @type {CurrentOpts} */ ({})) {
79
- assert(src, 'src is a required argument')
80
- assert(dest, 'dest is a required argument')
+ if (!src || typeof src !== 'string') throw new TypeError('src should be a (non-empty) string')
+ if (!dest || typeof dest !== 'string') throw new TypeError('dest should be a (non-empty) string')
81
+ if (!opts || typeof opts !== 'object') throw new TypeError('opts should be an object')
82
83
this.#src = src
84
this.#dest = dest
0 commit comments