og:thumb gefixt
This commit is contained in:
parent
a5a98dcab1
commit
c7bdf67436
|
@ -9,7 +9,7 @@
|
||||||
<link rel="icon" type="image/gif" href="./s/favicon.gif" />
|
<link rel="icon" type="image/gif" href="./s/favicon.gif" />
|
||||||
|
|
||||||
<meta name="Description" content="f0cked by {{ username }}" />
|
<meta name="Description" content="f0cked by {{ username }}" />
|
||||||
<meta property="og:image" content="{{ thumb }}" />
|
<meta property="og:image" content="{{ thumbnail }}" />
|
||||||
<meta charset="utf-8" />
|
<meta charset="utf-8" />
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
|
@ -107,6 +107,7 @@ function Websrv(tlib) {
|
||||||
userchannel: '',
|
userchannel: '',
|
||||||
usernetwork: '',
|
usernetwork: '',
|
||||||
thumb: null,
|
thumb: null,
|
||||||
|
thumbnail: null,
|
||||||
next: null,
|
next: null,
|
||||||
prev: null
|
prev: null
|
||||||
};
|
};
|
||||||
|
@ -135,6 +136,7 @@ function Websrv(tlib) {
|
||||||
data.srcurl = e.src;
|
data.srcurl = e.src;
|
||||||
data.src = urlm.parse(e.src).hostname;
|
data.src = urlm.parse(e.src).hostname;
|
||||||
data.thumb = (e.thumb != '' && e.thumb.match(/sndcdn\.com/i))?e.thumb:null;
|
data.thumb = (e.thumb != '' && e.thumb.match(/sndcdn\.com/i))?e.thumb:null;
|
||||||
|
data.thumbnail = `${lib.cfg.main.url}/t/${e.id}.png`;
|
||||||
data.dest = e.dest;
|
data.dest = e.dest;
|
||||||
data.mime = e.mime;
|
data.mime = e.mime;
|
||||||
data.size = lib.formatSize(e.size);
|
data.size = lib.formatSize(e.size);
|
||||||
|
@ -282,6 +284,7 @@ function Websrv(tlib) {
|
||||||
size: e.size,
|
size: e.size,
|
||||||
userchannel: e.userchannel,
|
userchannel: e.userchannel,
|
||||||
usernetwork: e.usernetwork,
|
usernetwork: e.usernetwork,
|
||||||
|
thumb: lib.cfg.main.url + "/t/" + e.id + ".png",
|
||||||
next: null,
|
next: null,
|
||||||
prev: null
|
prev: null
|
||||||
};
|
};
|
||||||
|
@ -306,6 +309,7 @@ function Websrv(tlib) {
|
||||||
else {
|
else {
|
||||||
res.writeHead(403);
|
res.writeHead(403);
|
||||||
res.end('403 - forbidden');
|
res.end('403 - forbidden');
|
||||||
|
console.log(req.connection.remoteAddress);
|
||||||
}
|
}
|
||||||
}).listen(lib.cfg.websrv.port);
|
}).listen(lib.cfg.websrv.port);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user