Mercurial Hosting > luan
diff src/luan/host/Util.luan @ 1418:732b5de211fc
add Hosted.luan
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Fri, 18 Oct 2019 22:29:46 -0600 |
parents | db57d562c4bd |
children | 60f6741f000a |
line wrap: on
line diff
--- a/src/luan/host/Util.luan Fri Oct 18 19:38:08 2019 -0600 +++ b/src/luan/host/Util.luan Fri Oct 18 22:29:46 2019 -0600 @@ -9,7 +9,7 @@ local format = String.format or error() local Binary = require "luan:Binary.luan" local bytes = Binary.byte or error() -local Hosting = require "luan:host/Hosting.luan" +local Hosted = require "luan:host/Hosted.luan" local Sql = require "luan:sql/Sql.luan" local database = Sql.database or error() local Logging = require "luan:logging/Logging.luan" @@ -24,7 +24,7 @@ function Util.read_password(domain) domain = lower(domain) - return do_file(Hosting.sites_dir..domain.."/info.luan").password or error() + return do_file(Hosted.sites_dir..domain.."/info.luan").password or error() end local function basic_authentication(dir,password) @@ -49,7 +49,7 @@ end function Util.set_password(domain,password) - local dir = Hosting.sites_dir..lower(domain) + local dir = Hosted.sites_dir..lower(domain) local file = Io.schemes.file(dir.."/info.luan") file.delete() file.write_text("return "..stringify{password=password}.."\n")