<?php
(static function($root){
require_once __DIR__.'/statement-write.php';if(!function_exists('json')){function json($data=[],$code=200,array $header=[],$options=[]){return \think\Response::create($data,'json',$code,$header,$options);}}
require $root.'/external_stubs.php';define('APP_PATH',__DIR__.'/source/application/');define('RUNTIME_PATH',__DIR__.'/runtime-write/');require $root.'/thinkphp/base.php';\think\App::initCommon();\think\Log::init(['type'=>'File','path'=>__DIR__.'/runtime-write/safe-log/','level'=>['no_raw_application_log']]);\think\Config::set(['type'=>'File','path'=>__DIR__.'/cache-write/','prefix'=>'NW11_'],'cache');\think\Config::set('redis',[]);$tpDb=require $root.'/application/database.php';$tpDb['debug']=true;$tpDb['params'][PDO::ATTR_STRINGIFY_FETCHES]=false;$tpDb['params'][PDO::ATTR_STATEMENT_CLASS]=['CDXStatement'];\think\Config::set($tpDb,'database');\think\Config::set('app_debug',false);\think\Config::set('app_trace',false);\think\Db::clear();\think\Loader::addNamespace('Overtrue\\Pinyin',$root.'/vendor/overtrue/pinyin/src');
})($root);
