luci-0.9: merge r5655
authorJo-Philipp Wich <jow@openwrt.org>
Tue, 23 Mar 2010 16:23:03 +0000 (16:23 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Tue, 23 Mar 2010 16:23:03 +0000 (16:23 +0000)
libs/lucid-http/luasrc/lucid/http/DirectoryPublisher.lua
libs/lucid-http/luasrc/lucid/http/LuciWebPublisher.lua
libs/lucid-http/luasrc/lucid/http/Redirector.lua

index f471781..b7cd846 100644 (file)
@@ -42,6 +42,6 @@ function factory(server, config)
                        vhost:set_handler(v, handler)
                end
        else
-               vhost:set_handler(config.virtual, handler)
+               vhost:set_handler(config.virtual or "", handler)
        end
-end
\ No newline at end of file
+end
index cd33caf..ad48588 100644 (file)
@@ -60,10 +60,10 @@ function factory(server, config)
                end
        else
                mypath = config.virtual
-               vhost:set_handler(config.virtual, handler)
+               vhost:set_handler(config.virtual or "", handler)
        end
 
        if config.home then
                vhost.default = mypath
        end
-end
\ No newline at end of file
+end
index c0af90b..bd3a1c6 100644 (file)
@@ -27,5 +27,5 @@ function factory(server, config)
        end
 
        local handler = catchall.Redirect(config.name, config.physical)
-       vhost:set_handler(config.virtual, handler)
-end
\ No newline at end of file
+       vhost:set_handler(config.virtual or "", handler)
+end