private static function checkOption($option, $request)
{
// 请求类型检测
if (isset($option['method']) && is_string($option['method']) && false === stripos($option['method'], $request->method()) || isset($option['ext']) && false === stripos($option['ext'], $request->ext()) || isset($option['deny_ext']) && false !== stripos($option['deny_ext'], $request->ext()) || isset($option['domain']) && !in_array($option['domain'], [$_SERVER['HTTP_HOST'], self::$subDomain]) || !empty($option['https']) && !$request->isSsl() || !empty($option['before_behavior']) && false === Hook::exec($option['before_behavior']) || !empty($option['callback']) && is_callable($option['callback']) && false === call_user_func($option['callback'])) {
return false;
}
return true;
}