mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-27 04:35:16 +01:00
Remove CVE ID check
Signed-off-by: sshijun <sshijun@vmware.com>
This commit is contained in:
parent
285d3e1e5c
commit
645e9331b0
@ -339,19 +339,8 @@ export class SystemSettingsComponent implements OnChanges, OnInit {
|
||||
}
|
||||
|
||||
isDisabled(): boolean {
|
||||
if (this.cveIds) {
|
||||
let arr = this.cveIds.split(/[\n,]+/);
|
||||
let flag = false;
|
||||
for (let i = 0; i < arr.length; i++) {
|
||||
let id = arr[i].trim();
|
||||
if (!/^CVE-[\d]+-[\d]+$/.test(id)) {
|
||||
flag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
return true;
|
||||
let str = this.cveIds;
|
||||
return !(str && str.trim());
|
||||
}
|
||||
|
||||
get expiresDate() {
|
||||
|
@ -303,19 +303,8 @@ export class ProjectPolicyConfigComponent implements OnInit {
|
||||
}
|
||||
|
||||
isDisabled(): boolean {
|
||||
if (this.cveIds) {
|
||||
let arr = this.cveIds.split(/[\n,]+/);
|
||||
let flag = false;
|
||||
for (let i = 0; i < arr.length; i++) {
|
||||
let id = arr[i].trim();
|
||||
if (!/^CVE-[\d]+-[\d]+$/.test(id)) {
|
||||
flag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
return true;
|
||||
let str = this.cveIds;
|
||||
return !(str && str.trim());
|
||||
}
|
||||
|
||||
get expiresDate() {
|
||||
|
Loading…
Reference in New Issue
Block a user