Sync DNS2 production changes - removed obsolete test suite and refactored structure
This commit is contained in:
@@ -56,7 +56,7 @@ module.exports = function(ctx) {
|
||||
res.json({
|
||||
success: true,
|
||||
path: `/assets/${safeFilename}`,
|
||||
message: `Logo saved to ${filePath}`,
|
||||
message: `Logo saved to ${filePath}`
|
||||
});
|
||||
}, 'assets-upload'));
|
||||
|
||||
@@ -75,7 +75,7 @@ module.exports = function(ctx) {
|
||||
customLogo: config.customLogo || config.customLogoDark || null,
|
||||
position: config.logoPosition || 'left',
|
||||
dashboardTitle: config.dashboardTitle || 'DashCaddy',
|
||||
isDefault: !config.customLogoDark && !config.customLogoLight && !config.customLogo,
|
||||
isDefault: !config.customLogoDark && !config.customLogoLight && !config.customLogo
|
||||
});
|
||||
}, 'logo-get'));
|
||||
|
||||
@@ -153,7 +153,7 @@ module.exports = function(ctx) {
|
||||
path: pathDark || pathLight,
|
||||
position: config.logoPosition || 'left',
|
||||
dashboardTitle: config.dashboardTitle || 'DashCaddy',
|
||||
message: 'Branding settings saved',
|
||||
message: 'Branding settings saved'
|
||||
});
|
||||
}, 'logo-upload'));
|
||||
|
||||
@@ -186,7 +186,7 @@ module.exports = function(ctx) {
|
||||
|
||||
res.json({
|
||||
success: true,
|
||||
message: 'Branding reset to defaults',
|
||||
message: 'Branding reset to defaults'
|
||||
});
|
||||
}, 'logo-delete'));
|
||||
|
||||
@@ -199,7 +199,7 @@ module.exports = function(ctx) {
|
||||
res.json({
|
||||
success: true,
|
||||
customFavicon: config.customFavicon || null,
|
||||
isDefault: !config.customFavicon,
|
||||
isDefault: !config.customFavicon
|
||||
});
|
||||
}, 'favicon-get'));
|
||||
|
||||
@@ -237,8 +237,8 @@ module.exports = function(ctx) {
|
||||
sharp(buffer)
|
||||
.resize(size, size, { fit: 'contain', background: { r: 0, g: 0, b: 0, alpha: 0 } })
|
||||
.png()
|
||||
.toBuffer(),
|
||||
),
|
||||
.toBuffer()
|
||||
)
|
||||
);
|
||||
|
||||
// Convert to ICO
|
||||
@@ -261,7 +261,7 @@ module.exports = function(ctx) {
|
||||
res.json({
|
||||
success: true,
|
||||
path: '/assets/favicon.ico',
|
||||
message: 'Favicon created successfully',
|
||||
message: 'Favicon created successfully'
|
||||
});
|
||||
}, 'favicon'));
|
||||
|
||||
@@ -285,7 +285,7 @@ module.exports = function(ctx) {
|
||||
|
||||
res.json({
|
||||
success: true,
|
||||
message: 'Favicon reset to default',
|
||||
message: 'Favicon reset to default'
|
||||
});
|
||||
}, 'favicon-delete'));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user