🎨 优化
commit
2eeb0a230e
|
@ -0,0 +1,21 @@
|
|||
# Security Policy
|
||||
|
||||
## Supported Versions
|
||||
|
||||
Use this section to tell people about which versions of your project are
|
||||
currently being supported with security updates.
|
||||
|
||||
| Version | Supported |
|
||||
| ------- | ------------------ |
|
||||
| 5.1.x | :white_check_mark: |
|
||||
| 5.0.x | :x: |
|
||||
| 4.0.x | :white_check_mark: |
|
||||
| < 4.0 | :x: |
|
||||
|
||||
## Reporting a Vulnerability
|
||||
|
||||
Use this section to tell people how to report a vulnerability.
|
||||
|
||||
Tell them where to go, how often they can expect to get an update on a
|
||||
reported vulnerability, what to expect if the vulnerability is accepted or
|
||||
declined, etc.
|
|
@ -2,7 +2,7 @@
|
|||
* @Author: early-autumn
|
||||
* @Date: 2020-04-17 12:18:25
|
||||
* @LastEditors: early-autumn
|
||||
* @LastEditTime: 2020-04-22 09:25:03
|
||||
* @LastEditTime: 2020-04-22 09:37:49
|
||||
*/
|
||||
import { Adapter, Platform } from './types';
|
||||
|
||||
|
@ -34,14 +34,13 @@ const stack = [
|
|||
function adaptive(): Adapter | undefined {
|
||||
let adapter: Adapter | undefined;
|
||||
|
||||
const platform = stack.shift();
|
||||
|
||||
if (platform === undefined) {
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
const platform = stack.shift();
|
||||
|
||||
if (platform === undefined) {
|
||||
return;
|
||||
}
|
||||
|
||||
// platform() 可能会导致程序进入 catch
|
||||
adapter = platform();
|
||||
} catch (err) {}
|
||||
|
||||
|
|
Loading…
Reference in New Issue