Skip to content

Commit

Permalink
fixed missing rpki api option (#1005)
Browse files Browse the repository at this point in the history
  • Loading branch information
massimocandela committed Jan 6, 2023
1 parent 24d1cdd commit 50e2662
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/utils/rpkiUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export default class RpkiUtils {
this.logger = env.logger;
this.userAgent = `${this.clientId}/${env.version}`;
const defaultMarkDataAsStaleAfterMinutes = 60;
const providers = RpkiValidator.providers;
const providers = ["api", ...RpkiValidator.providers];

if (this.params.url || this.params.vrpProvider === "api") {
this.params.vrpProvider = "api";
Expand Down Expand Up @@ -44,7 +44,7 @@ export default class RpkiUtils {
});
}
this.params.refreshVrpListMinutes = Math.max(this.params.refreshVrpListMinutes || 0, 5);
this.params.preCacheROAs = this.params.preCacheROAs !== false;
this.params.preCacheROAs = !!(this.params.preCacheROAs ?? true);
}

if (this.params.markDataAsStaleAfterMinutes !== undefined) {
Expand Down Expand Up @@ -87,7 +87,7 @@ export default class RpkiUtils {
}
this.rpki = new RpkiValidator(rpkiValidatorOptions);

if (!!this.params.preCacheROAs) {
if (this.params.preCacheROAs) {
this._preCache();
}
}
Expand Down

0 comments on commit 50e2662

Please sign in to comment.