webmcp

changeset 330:22275c74023a

Modified error message when setting global variable
author jbe
date Tue Mar 24 13:30:54 2015 +0100 (2015-03-24)
parents 3db9b672ee73
children 264af2867720
files framework/bin/mcp.lua
line diff
     1.1 --- a/framework/bin/mcp.lua	Tue Mar 24 12:32:31 2015 +0100
     1.2 +++ b/framework/bin/mcp.lua	Tue Mar 24 13:30:54 2015 +0100
     1.3 @@ -27,7 +27,7 @@
     1.4          _G[key] = value
     1.5        else
     1.6          if type(key) == "string" and string.match(key, "^[A-Za-z_][A-Za-z_0-9]*$") then
     1.7 -          error('Attempt to set global variable "' .. key .. '" (hint: use _G.' .. key .. '=<value> to override protection mechanism)', 2)
     1.8 +          error('Attempt to set global variable "' .. key .. '" (Hint: missing local statement? Use _G.' .. key .. '=<value> to really set global variable)', 2)
     1.9          else
    1.10            error('Attempt to set global variable', 2)
    1.11          end

Impressum / About Us