buggsen gefiggst
This commit is contained in:
parent
395ebbe9f8
commit
a23c3a059e
|
@ -34,7 +34,15 @@ function Websrv(tbot, tsql, tlib) {
|
||||||
body = JSON.parse(body);
|
body = JSON.parse(body);
|
||||||
var eventname = body.event_name;
|
var eventname = body.event_name;
|
||||||
var autor = body.user_name;
|
var autor = body.user_name;
|
||||||
var commit = body.commits[body.commits.length-1].message.replace('\n','').trim();
|
|
||||||
|
var commit = "";
|
||||||
|
try {
|
||||||
|
commit = body.commits[body.commits.length-1].message.replace('\n','').trim();
|
||||||
|
}
|
||||||
|
catch(ex) {
|
||||||
|
commit body.commits[body.commits.length-2].message.replace('\n','').trim();
|
||||||
|
}
|
||||||
|
|
||||||
lib.log( eventname + ' from ' + autor + ' ('+commit+')' );
|
lib.log( eventname + ' from ' + autor + ' ('+commit+')' );
|
||||||
});
|
});
|
||||||
res.writeHead(200, { 'Content-Type': 'text/html' });
|
res.writeHead(200, { 'Content-Type': 'text/html' });
|
||||||
|
|
Loading…
Reference in New Issue
Block a user