                 ctrl = require 'pages/' + name
                 ctrl::name = 'pages:' + name
             ctrl::view = ctrlPath
-            if _.isString ctrl::path
+            if typeof ctrl::path == 'string'
                 ctrl::path = moduleInfo.url + ctrl::path  or  '/'
             else
                 ctrl::path =

        app.modules = {}
        globalPaths = module.constructor.globalPaths
        for moduleInfo in options.modules
            if _.isString moduleInfo
                moduleInfo = name: moduleInfo
            app.modules[moduleInfo.name] = _.defaults moduleInfo,
                path:
                    if moduleInfo.name
                        resolve.sync moduleInfo.name,

        app.component require name

    for moduleInfo in options.modules
        if typeof moduleInfo == 'string'
            moduleInfo = name: moduleInfo
        moduleName = moduleInfo.name

        for k, v of app.modules[moduleName]
            moduleInfo[k] ?= v

        require moduleName if moduleInfo.index

        if moduleInfo.opts
            opts = require moduleName + '/opts'
            Object.assign opts, moduleInfo

        for name in moduleInfo.components
            compPath = path.join moduleInfo.path, 'components', name
