@thezelijah/majik-message 1.0.3 → 1.0.4

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.
@@ -1,5 +1,6 @@
1
1
  import { autogenerateID } from "./utils";
2
2
  import { hash } from "@stablelib/sha256";
3
+ import { arrayToBase64 } from "../../utils/utilities";
3
4
  /**
4
5
  * Utility assertions
5
6
  */
@@ -16,7 +17,7 @@ function assertISODate(value, field) {
16
17
  }
17
18
  function sha256(input) {
18
19
  const hashed = hash(new TextEncoder().encode(input));
19
- return hashed.toString();
20
+ return arrayToBase64(hashed);
20
21
  }
21
22
  /**
22
23
  * MajikMessageIdentity
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@thezelijah/majik-message",
3
3
  "type": "module",
4
4
  "description": "Encrypt and decrypt messages on any website. Secure chats with keypairs and seed-based accounts. Open source.",
5
- "version": "1.0.3",
5
+ "version": "1.0.4",
6
6
  "license": "Apache-2.0",
7
7
  "author": "Zelijah",
8
8
  "main": "./dist/index.js",