diff options
author | thomascube <thomas@roundcube.net> | 2011-04-20 08:48:29 +0000 |
---|---|---|
committer | thomascube <thomas@roundcube.net> | 2011-04-20 08:48:29 +0000 |
commit | 49dac95d7d33f7b640e99db8d0ac4a108a10edb0 (patch) | |
tree | 5e6c769eaae18a17348b1c1b5746a5f1c8dbd9dd /program/include | |
parent | 4687446d005d19d24cf67e3f0f061a2b411ca041 (diff) |
Don't add env variable when template is empty (e.g. on error page)
Diffstat (limited to 'program/include')
-rwxr-xr-x | program/include/rcube_template.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/program/include/rcube_template.php b/program/include/rcube_template.php index 0a64d1cb1..fdfa15cec 100755 --- a/program/include/rcube_template.php +++ b/program/include/rcube_template.php @@ -342,7 +342,8 @@ class rcube_template extends rcube_html_page array_unshift($this->js_commands, array('hide_message', $unlock)); } - $this->set_env('request_token', $this->app->get_request_token()); + if (!empty($this->script_files)) + $this->set_env('request_token', $this->app->get_request_token()); // write all env variables to client $js = $this->framed ? "if(window.parent) {\n" : ''; |