modify
This commit is contained in:
@@ -111,7 +111,7 @@ class HTTPServerListener extends Abstracts\Server
|
|||||||
} else {
|
} else {
|
||||||
$this->router->dispatch();
|
$this->router->dispatch();
|
||||||
}
|
}
|
||||||
} catch (ExitException | Error | Throwable $exception) {
|
} catch (Error | Throwable $exception) {
|
||||||
$response->setHeader('Content-Type', 'text/html; charset=utf-8');
|
$response->setHeader('Content-Type', 'text/html; charset=utf-8');
|
||||||
$response->status($exception->getCode() == 0 ? 500 : $exception->getCode());
|
$response->status($exception->getCode() == 0 ? 500 : $exception->getCode());
|
||||||
$response->end($exception->getMessage());
|
$response->end($exception->getMessage());
|
||||||
|
|||||||
@@ -271,6 +271,9 @@ class ServerInotify implements CustomProcess
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
const IG_DIR = [APP_PATH . 'commands', APP_PATH . '.git', APP_PATH . '.gitee'];
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param $dir
|
* @param $dir
|
||||||
* @return bool
|
* @return bool
|
||||||
@@ -287,7 +290,7 @@ class ServerInotify implements CustomProcess
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (in_array($dir, [APP_PATH . 'commands', APP_PATH . '.git', APP_PATH . '.gitee'])) {
|
if (in_array($dir, self::IG_DIR)) {
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user