Misc: little style changes
This commit is contained in:
parent
35458fd7f3
commit
603f78b0c5
1 changed files with 3 additions and 5 deletions
|
@ -4,8 +4,7 @@ local vmf = get_mod("VMF")
|
||||||
-- ##### VMF internal functions and variables ##########################################################################
|
-- ##### VMF internal functions and variables ##########################################################################
|
||||||
-- #####################################################################################################################
|
-- #####################################################################################################################
|
||||||
|
|
||||||
vmf.check_wrong_argument_type = function(mod, vmf_function_name, argument_name, argument, ...)
|
function vmf.check_wrong_argument_type(mod, vmf_function_name, argument_name, argument, ...)
|
||||||
|
|
||||||
local allowed_types = {...}
|
local allowed_types = {...}
|
||||||
local argument_type = type(argument)
|
local argument_type = type(argument)
|
||||||
|
|
||||||
|
@ -15,8 +14,7 @@ vmf.check_wrong_argument_type = function(mod, vmf_function_name, argument_name,
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
mod:error("(%s): argument '%s' should have the '%s' type, not '%s'",
|
mod:error("(%s): argument '%s' should have the '%s' type, not '%s'", vmf_function_name, argument_name,
|
||||||
vmf_function_name, argument_name, table.concat(allowed_types, "/"), argument_type)
|
table.concat(allowed_types, "/"), argument_type)
|
||||||
|
|
||||||
return true
|
return true
|
||||||
end
|
end
|
Loading…
Add table
Reference in a new issue