mirror of
https://github.com/actions/javascript-action.git
synced 2025-04-07 15:59:40 +00:00
11 lines
261 B
JavaScript
11 lines
261 B
JavaScript
let wait = function (milliseconds) {
|
|
return new Promise((resolve) => {
|
|
if (typeof milliseconds !== 'number') {
|
|
throw new Error('milliseconds not a number');
|
|
}
|
|
setTimeout(() => resolve("done!"), milliseconds)
|
|
});
|
|
};
|
|
|
|
module.exports = wait;
|