File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -123,14 +123,15 @@ public function beforeCompile(){
123
123
* @param Request $request
124
124
*/
125
125
public static function register_shutdown (Scripter $ scripter , Response $ response , Request $ request ){
126
- register_shutdown_function (function ()use ($ scripter , $ response ){
126
+ register_shutdown_function (function ()use ($ scripter , $ response, $ request ){
127
127
128
128
$ page = ob_get_contents ();
129
129
ob_end_clean ();
130
130
131
131
$ header_type = $ response ->getHeader ("Content-Type " );
132
132
133
- if ($ header_type && strpos ($ header_type , "text/html " ) === 0 ){
133
+ if ($ header_type && strpos ($ header_type , "text/html " ) === 0 && !$ request ->isAjax ()){
134
+
134
135
$ scripter ->cache ->removeNotUseFile ();
135
136
preg_match ('/(?:<head[^>]*>)(.*?)<\/head>/s ' , $ page , $ matches );
136
137
if (isset ($ matches [1 ])){
You can’t perform that action at this time.
0 commit comments