Skip to content

Commit 1ae5a7a

Browse files
committed
ConfigHandler: support single section key to passed without being wrapped into a table
1 parent 1610e35 commit 1ae5a7a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

modules/DependencyControl/ConfigHandler.moon

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@ class ConfigHandler
2727
-- waitingLockTimeout: "Timeout was reached after %d seconds, force-releasing lock..."
2828
}
2929

30-
new: (@file, @defaults = {}, @section = {}, noLoad, @logger = Logger fileBaseName: @@__name) =>
30+
new: (@file, @defaults = {}, @section, noLoad, @logger = Logger fileBaseName: @@__name) =>
31+
@section = {@section} if "table" != type @section
3132
-- register all handlers for concerted writing
3233
@setFile @file
3334

0 commit comments

Comments
 (0)