avatar blob now comes in only via branding api calls

This commit is contained in:
Johannes Zellner
2020-06-02 15:13:50 +02:00
parent b602e921d0
commit 2b3c4cf0ff

View File

@@ -240,9 +240,7 @@ function initializeExpressSync() {
// settings routes (these are for the settings tab - avatar & name have public routes for normal users. see above)
router.get ('/api/v1/settings/:setting', token, authorizeAdmin, routes.settings.get);
router.post('/api/v1/settings/backup_config', token, authorizeOwner, routes.settings.setBackupConfig);
router.post('/api/v1/settings/:setting', token, authorizeAdmin, (req, res, next) => {
return req.params.setting === 'cloudron_avatar' ? multipart(req, res, next) : next();
}, routes.settings.set);
router.post('/api/v1/settings/:setting', token, authorizeAdmin, routes.settings.set);
// email routes
router.get('/api/v1/mailserver/:pathname', token, (req, res, next) => {