Mercurial Hosting > luan
diff http/src/luan/modules/http/Http.luan @ 509:e3b0846dc2ef
throw exception for invalid indexes of string, binary, or java
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Fri, 22 May 2015 02:02:49 -0600 |
parents | 9218f9cf45d3 |
children | aa17ad66a370 |
line wrap: on
line diff
--- a/http/src/luan/modules/http/Http.luan Thu May 21 20:20:54 2015 -0600 +++ b/http/src/luan/modules/http/Http.luan Fri May 22 02:02:49 2015 -0600 @@ -16,7 +16,7 @@ function singular_metatable.__index(table,key) local list = table.__plural[key] - return list and (list[1] or error("invalid value "..list.." for "..key)) + return list and list[1] end function singular_metatable.__new_index(table,key,value)