fixed srclink
This commit is contained in:
parent
a497d65395
commit
8f708f8819
1
bot.js
1
bot.js
|
@ -46,6 +46,7 @@ child.on('start', () => {
|
|||
});
|
||||
child.on('exit:code', (code) => {
|
||||
putlog('detected bot exited with code ' + code + '\n');
|
||||
child.restart();
|
||||
});
|
||||
child.on('stderr', (data) => {
|
||||
putlog(data);
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
</div>
|
||||
<div class="controls">{% if next != null %}<a id="next" href="/{{ next }}"><<-</a> | {% endif %} <a id="random" href="/random" title="Random">random</a> {% if prev != null %} | <a id="prev" href="/{{ prev }}">->></a>{% endif %}</div><br />
|
||||
<div class="info">
|
||||
<span class="src">src: <a href="{{ src }}" target="_blank">{{ src }}</a></span><br />
|
||||
<span class="src">src: <a href="{{ srcurl }}" target="_blank">{{ src }}</a></span><br />
|
||||
<span class="dest">dest: {{ dest }}</span><br />
|
||||
<span class="mime">mime: {{ mime }}</span>
|
||||
<span class="size">size: {{ size }}</span><br />
|
||||
|
|
|
@ -2,6 +2,7 @@ var fs = require('fs-extra');
|
|||
var http = require('http');
|
||||
var path = require('path');
|
||||
var swig = require('swig');
|
||||
var urlm = require('url');
|
||||
var cfg = require('../cfg/websrv.json');
|
||||
|
||||
var templates = {};
|
||||
|
@ -89,7 +90,10 @@ function Websrv(tbot, tsql, tlib) {
|
|||
}
|
||||
data.id = e.id;
|
||||
data.username = e.username;
|
||||
data.src = e.src;
|
||||
|
||||
data.srcurl = e.src;
|
||||
data.src = urlm.parse(e.src).hostname;
|
||||
|
||||
data.dest = e.dest;
|
||||
data.mime = e.mime;
|
||||
data.size = lib.formatSize(e.size);
|
||||
|
|
Loading…
Reference in New Issue
Block a user