mirror of
https://github.com/azures04/crafatar.git
synced 2026-03-22 07:51:17 +01:00
oops 💩
This commit is contained in:
parent
fdb52d7d0f
commit
0734060d96
@ -92,7 +92,7 @@ router.get('/avatars/:uuid.:ext?', function(req, res) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function handle_default(http_status, img_status) {
|
function handle_default(http_status, img_status) {
|
||||||
if (def != "steve" && def != "alex") {
|
if (def && def != "steve" && def != "alex") {
|
||||||
res.writeHead(301, {
|
res.writeHead(301, {
|
||||||
'Cache-Control': 'max-age=' + config.browser_cache_time + ', public',
|
'Cache-Control': 'max-age=' + config.browser_cache_time + ', public',
|
||||||
'Response-Time': new Date() - start,
|
'Response-Time': new Date() - start,
|
||||||
@ -101,7 +101,7 @@ router.get('/avatars/:uuid.:ext?', function(req, res) {
|
|||||||
});
|
});
|
||||||
res.end();
|
res.end();
|
||||||
} else {
|
} else {
|
||||||
def = def || skins.default_skin;
|
def = def || skins.default_skin(uuid);
|
||||||
skins.resize_img("public/images/" + def + ".png", size, function(err, image) {
|
skins.resize_img("public/images/" + def + ".png", size, function(err, image) {
|
||||||
sendimage(http_status, img_status, image);
|
sendimage(http_status, img_status, image);
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user