• Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
v3.5.2 Latest
Buy Hosting

Theme and stylesheet loading issues

Scheduled Pinned Locked Moved Bug Reports
26 Posts 3 Posters 8.8k Views
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    datz
    wrote on last edited by
    #17

    excuse me

    on upgrade

    info: [2014/2/20] Activating NodeBB Essential Widgets
    warn: [plugins/nodebb-plugin-youtube] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-youtube] staticDir is deprecated, define CSS files with new staticDirs instead.
    warn: [plugins/nodebb-plugin-blog-comments] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-widget-essentials] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-widget-essentials] staticDir is deprecated, define CSS files with new staticDirs instead.
    warn: [plugins/nodebb-plugin-chat-emote] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-chat-emote] staticDir is deprecated, define CSS files with new staticDirs instead.
    warn: [plugins/nodebb-plugin-sso-github] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-imgur] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-sso-google] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-rss] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-sso-twitter] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-emoji-skype] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-emoji-skype] staticDir is deprecated, define CSS files with new staticDirs instead.
    warn: [plugins/nodebb-plugin-cash] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-cash] staticDir is deprecated, define CSS files with new staticDirs instead.
    warn: [plugins/nodebb-plugin-vimeo] staticDir is deprecated, use staticDirs instead
    warn: [plugins/nodebb-plugin-vimeo] staticDir is deprecated, define CSS files with new staticDirs instead.
    info: Enabling 'trust proxy'
    error: [app] Encountered Uncaught Exception: path must be a string
    TypeError: path must be a string
    at Object.fs.readdir (fs.js:649:11)
    at Object.Meta.themes.get (/home/ubuntu/community/src/meta.js:89:7)
    at /home/ubuntu/community/src/webserver.js:350:19
    at /home/ubuntu/community/node_modules/async/lib/async.js:505:21
    at /home/ubuntu/community/node_modules/async/lib/async.js:221:13
    at /home/ubuntu/community/node_modules/async/lib/async.js:105:13
    at Array.forEach (native)
    at _each (/home/ubuntu/community/node_modules/async/lib/async.js:32:24)
    at async.each (/home/ubuntu/community/node_modules/async/lib/async.js:104:9)
    at _asyncMap (/home/ubuntu/community/node_modules/async/lib/async.js:220:9)
    error: [app] Could not restart server. Shutting down.
    info: [app] Shutdown (SIGTERM/SIGINT) Initialised.
    info: [app] Database connection closed.
    info: [app] Goodbye!

    1 Reply Last reply
    0
  • D Offline
    D Offline
    datz
    wrote on last edited by
    #18

    error: [app] Encountered Uncaught Exception: path must be a string

    1 Reply Last reply
    0
  • D Offline
    D Offline
    datz
    wrote on last edited by
    #19

    ###themePath not a string? or file names not string? possible hidden files .file?
    fs.readdir(themePath, function (err, files) {
    async.filter(files, function (file, next) {
    fs.stat(path.join(themePath, file), function (err, fileStat) {
    if (err) {
    return next(false);
    }

                                                next((fileStat.isDirectory() && file.slice(0, 13) === 'nodebb-theme-'));
                                        });
                                }, function (themes) {
                                        async.map(themes, function (theme, next) {
                                                var config = path.join(themePath, theme, 'theme.json');
    
                                                if (fs.existsSync(config)) {
                                                        fs.readFile(config, function (err, file) {
                                                                if (err) return next();
                                                                else {
                                                                        var configObj = JSON.parse(file.toString());
                                                                        next(err, configObj);
                                                                }
                                                        });
                                                } else {
                                                        next();
                                                }
                                        }, function (err, themes) {
                                                themes = themes.filter(function (theme) {
                                                        return (theme !== undefined);
                                                });
                                                callback(null, themes);
                                        });
                                });
                        });
    
    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #20

    https://github.com/designcreateplay/NodeBB/blob/master/src/meta.js#L88 can you add console.log(themePath); on that line and let me know the result?

    D 1 Reply Last reply
    0
  • D Offline
    D Offline
    datz
    replied to <baris> on last edited by
    #21

    console.log(themePath);

    @baris undefined

    1 Reply Last reply
    0
  • D Offline
    D Offline
    datz
    wrote on last edited by
    #22

    where is it defined? where does nconf trace to? can i redefine it? what is the proper path?

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #23

    Can you test with https://github.com/designcreateplay/NodeBB/commit/fb1313ec90ff093dd28aed205f9b7882ee82bd06 looks like themes_path wasnt set in upgrade

    D 2 Replies Last reply
    0
  • D Offline
    D Offline
    datz
    replied to <baris> on last edited by
    #24

    @baris ok we are good to go.

    1 Reply Last reply
    0
  • D Offline
    D Offline
    datz
    replied to <baris> on last edited by
    #25

    @baris also, how can i set a user as an admin from the redis-cli command line?

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by baris
    #26

    It is better to do that from the admin control panel.

    But if you don't have access to the ACP.

    hget group:gid administrators
    "1" <- use this value
    sadd  gid:1:members <uid> 
    

    replace <uid> with your user id.

    To get the user id use :

    hget username:uid <yourusername>
    
    1 Reply Last reply
    0

Copyright © 2023 NodeBB | Contributors
  • Login

  • Don't have an account? Register

  • Login or register to search.
Powered by NodeBB Contributors
  • First post
    Last post
0
  • Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development