mirror of
https://github.com/NuSkooler/enigma-bbs.git
synced 2025-07-20 17:55:53 +02:00
* Added ability to serve static files from web server
* Web server can have custom error pages, e.g. 404.html * "file_area" stuff -> "file_base" * Fix some rare bugs in theme/art loading * Adjust tab order dynamically for file upload details
This commit is contained in:
parent
ff64a7aed5
commit
92772eb1a9
14 changed files with 165 additions and 48 deletions
|
@ -354,16 +354,16 @@ function setClientTheme(client, themeId) {
|
|||
function getThemeArt(options, cb) {
|
||||
//
|
||||
// options - required:
|
||||
// name
|
||||
// client
|
||||
// name
|
||||
//
|
||||
// options - optional
|
||||
// themeId
|
||||
// asAnsi
|
||||
// readSauce
|
||||
// random
|
||||
// client - needed for user's theme/etc.
|
||||
// themeId
|
||||
// asAnsi
|
||||
// readSauce
|
||||
// random
|
||||
//
|
||||
if(!options.themeId && _.has(options.client, 'user.properties.theme_id')) {
|
||||
if(!options.themeId && _.has(options, 'client.user.properties.theme_id')) {
|
||||
options.themeId = options.client.user.properties.theme_id;
|
||||
} else {
|
||||
options.themeId = Config.defaults.theme;
|
||||
|
@ -437,9 +437,13 @@ function getThemeArt(options, cb) {
|
|||
],
|
||||
function complete(err, artInfo) {
|
||||
if(err) {
|
||||
options.client.log.debug( { error : err }, 'Cannot find art');
|
||||
if(options.client) {
|
||||
options.client.log.debug( { error : err.message }, 'Cannot find theme art' );
|
||||
} else {
|
||||
Log.debug( { error : err.message }, 'Cannot find theme art' );
|
||||
}
|
||||
}
|
||||
cb(err, artInfo);
|
||||
return cb(err, artInfo);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue