diff --git a/src/Repository.ts b/src/Repository.ts index fbb7fef..bfeaa15 100644 --- a/src/Repository.ts +++ b/src/Repository.ts @@ -91,9 +91,9 @@ export default class Repository { * Check the status of the repository */ check() { - if (this._model.options.expirationMode != "never") { - if (this._model.options.expirationDate > new Date()) { - this.updateStatus("expired"); + if (this._model.options.expirationMode !== "never") { + if (this._model.options.expirationDate <= new Date()) { + this.expire(); } } if (this._model.status == "expired") {