Browse Source

paypro: example - use GET method for first paypro request.

patch-2
Christopher Jeffrey 11 years ago
parent
commit
c33eef3689
  1. 4
      examples/PayPro/server.js

4
examples/PayPro/server.js

@ -73,7 +73,7 @@ app.use(function(req, res, next) {
res.setHeader('Access-Control-Allow-Origin', '*');
if (req.method === 'OPTIONS') {
res.setHeader('Access-Control-Allow-Methods', 'OPTIONS,GET,PUT,POST,PATCH,DELETE');
res.setHeader('Access-Control-Allow-Methods', 'GET,POST');
res.setHeader('Access-Control-Allow-Headers', req.headers['access-control-request-headers']);
return res.send(200);
}
@ -124,7 +124,7 @@ app.use('/-/pay', function(req, res, next) {
app.uid = 0;
app.post('/-/request', function(req, res, next) {
app.get('/-/request', function(req, res, next) {
print('Received payment "request" from %s.', req.socket.remoteAddress);
var outputs = [];

Loading…
Cancel
Save