summaryrefslogtreecommitdiffhomepage
path: root/test/node/promise_end/app.js
blob: 373c3bc6f18d1c69599c6cbf49def8e813edeb3c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15

var fs = require('fs');

require('http').createServer(function (req, res) {
    res.write('blah');

    Promise.resolve().then(() => {
        res.end();
    });

    req.on('data', (data) => {
        fs.appendFile('callback', '', function() {});
    });

}).listen(7080);