diff core/configmanager.lua @ 4530:40905e7bf680

configmanager: get(): Make section (core) optional (hurrah)
author Matthew Wild <mwild1@gmail.com>
date Sat, 10 Dec 2011 17:21:19 +0000
parents 86be454168fb
children 85b2689dbcfe
line wrap: on
line diff
--- a/core/configmanager.lua	Wed Nov 30 19:37:13 2011 +0000
+++ b/core/configmanager.lua	Sat Dec 10 17:21:19 2011 +0000
@@ -41,6 +41,9 @@
 end
 
 function get(host, section, key)
+	if not key then
+		section, key = "core", section;
+	end
 	local sec = config[host][section];
 	if sec then
 		return sec[key];