better handling #478

This commit is contained in:
lesion 2025-01-22 13:02:04 +01:00
parent fed37c04da
commit f1eb392a24
No known key found for this signature in database
GPG key ID: 352918250B012177

View file

@ -10,7 +10,7 @@ const get = require('lodash/get')
module.exports = {
get (req, res) {
if (req.accepts(['html','json']) === 'html') {
if (req.accepts(['json','html']) !== 'json') {
log.debug('[FEDI] Get actor but prefer text/html, redirect to homepage')
return res.redirect(301, '/')
}