webmcp
diff framework/env/slot/layout_is_set.lua @ 492:93ebbc1e5dbc
Allow actions to directly return content (e.g. for XMLHttpRequests) by calling slot.set_layout(...) during request handling
author | jbe |
---|---|
date | Tue Jun 27 17:34:02 2017 +0200 (2017-06-27) |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/framework/env/slot/layout_is_set.lua Tue Jun 27 17:34:02 2017 +0200 1.3 @@ -0,0 +1,11 @@ 1.4 +--[[-- 1.5 +bool = -- set to true if layout has been set explicitly during processing request 1.6 +slot.layout_is_set() 1.7 + 1.8 +Returns true if slot.set_layout(...) has been called during handling of a request. 1.9 + 1.10 +--]]-- 1.11 + 1.12 +function slot.layout_is_set() 1.13 + return slot._layout_set 1.14 +end