@usync/oauth2 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -635,7 +635,7 @@ var N = class {
635
635
  async getToken() {
636
636
  let e = await this.options.storage.get("accessToken");
637
637
  if (!e) throw new i(3);
638
- if (e.expiresAt > Date.now()) throw new i(1);
638
+ if (e.expiresAt < Date.now()) throw new i(1);
639
639
  return e.token;
640
640
  }
641
641
  }, P = class extends N {
@@ -1,4 +1,4 @@
1
- import { IOAuth2Options } from '../types';
1
+ import { IOAuth2Options } from "../types";
2
2
  export declare abstract class OAuth2Authorizer {
3
3
  protected options: IOAuth2Options;
4
4
  abstract buildAuthUrl(): Promise<string>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@usync/oauth2",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {