mirror of
https://github.com/nttgin/BGPalerter.git
synced 2024-05-19 06:50:08 +00:00
added research environment in order to reduce production constraints
This commit is contained in:
@@ -145,6 +145,10 @@ export default class InputYml extends Input {
|
||||
return "Not a valid prefix: " + prefix;
|
||||
}
|
||||
|
||||
|
||||
if (this.config.environment === "research") {
|
||||
item.asn = item.asn || 0;
|
||||
}
|
||||
if (["string", "number"].includes(typeof(item.asn))) {
|
||||
asns = [item.asn];
|
||||
} else if (item.asn instanceof Array) {
|
||||
@@ -153,6 +157,7 @@ export default class InputYml extends Input {
|
||||
return "Not a valid AS number for: " + prefix;
|
||||
}
|
||||
|
||||
|
||||
if (!new AS(asns).isValid()) {
|
||||
return "Not a valid AS number for: " + prefix;
|
||||
}
|
||||
|
Reference in New Issue
Block a user