Software /
code /
prosody
Diff
core/storagemanager.lua @ 6792:8b284787fe26
storagemanager: Add forward declaration to fix use of open() before it's defined
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 20 Aug 2015 23:57:22 +0200 |
parent | 6791:e813e8cf6046 |
child | 6811:82350a06df6e |
line wrap: on
line diff
--- a/core/storagemanager.lua Thu Aug 20 13:05:22 2015 +0200 +++ b/core/storagemanager.lua Thu Aug 20 23:57:22 2015 +0200 @@ -100,6 +100,9 @@ end; }; } + +local open; -- forward declaration + local function create_map_shim(host, store) local keyval_store, err = open(host, store, "keyval"); if keyval_store == nil then return nil, err end @@ -108,7 +111,7 @@ }, map_shim_mt); end -local function open(host, store, typ) +function open(host, store, typ) local driver, driver_name = get_driver(host, store); local ret, err = driver:open(store, typ); if not ret then