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 cf92571 commit eb34008Copy full SHA for eb34008
lib/predictions.js
@@ -27,7 +27,8 @@ async function createPrediction(options) {
27
const headers = {};
28
if (wait) {
29
if (typeof wait === "number") {
30
- headers["Prefer"] = `wait=${wait}`;
+ const n = Math.max(1, Math.ceil(Number(wait)) || 1);
31
+ headers["Prefer"] = `wait=${n}`;
32
} else {
33
headers["Prefer"] = "wait";
34
}
0 commit comments