Skip to content

Commit c9e5dbf

Browse files
committed
Rename then in example.
1 parent 017ee42 commit c9e5dbf

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

jscomp/test/SafePromises.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ var Js_promise2 = require("../../lib/js/js_promise2.js");
44

55
async function nestedPromise(xxx) {
66
var xx = await xxx;
7-
Js_promise2.then_(xx, (function (x) {
8-
return Promise.resolve((console.log("Promise2.then_", x), undefined));
7+
Js_promise2.then(xx, (function (x) {
8+
return Promise.resolve((console.log("Promise2.then", x), undefined));
99
}));
1010
Js_promise2.$$catch(xx, (function (x) {
1111
console.log("Promise2.catch_", x);

jscomp/test/SafePromises.res

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
let nestedPromise = async (xxx: promise<promise<int>>) => {
44
let xx = await xxx
55

6-
let _ = xx->Js.Promise2.then_(x => Js.log2("Promise2.then_", x) |> Js.Promise.resolve)
6+
let _ = xx->Js.Promise2.then(x => Js.log2("Promise2.then", x) |> Js.Promise.resolve)
77
let _ = xx->Js.Promise2.catch(x => {
88
Js.log2("Promise2.catch_", x)
99
0 |> Js.Promise.resolve

0 commit comments

Comments
 (0)