diff --git a/lib/node_modules/@stdlib/_tools/github/dispatch-workflow/lib/query.js b/lib/node_modules/@stdlib/_tools/github/dispatch-workflow/lib/query.js index e59357b6b992..e2af0477542e 100644 --- a/lib/node_modules/@stdlib/_tools/github/dispatch-workflow/lib/query.js +++ b/lib/node_modules/@stdlib/_tools/github/dispatch-workflow/lib/query.js @@ -83,7 +83,18 @@ function query( slug, id, options, clbk ) { info = ratelimit( response.headers ); debug( 'Rate limit: %d', info.limit ); debug( 'Rate limit remaining: %d', info.remaining ); - debug( 'Rate limit reset: %s', (new Date( info.reset*1000 )).toISOString() ); + + if ( typeof info.reset === 'number' ) { + var resetTime = new Date( info.reset * 1000 ); + var time = resetTime.getTime(); + + debug( + 'Rate limit reset: %s', + isNaN( time ) ? 'invalid timestamp' : resetTime.toISOString() + ); + } else { + debug( 'Rate limit reset: not provided' ); + } if ( error ) { return clbk( error, info );