HugoRodriguesQW / rsa-bridge

Encrypted communication bridge using RSA keys between frontend and backend
https://rsa-bridge.vercel.app
MIT License
1 stars 0 forks source link

Invalid ContentType in RSAServer.Publish #3

Open HugoRodriguesQW opened 4 months ago

HugoRodriguesQW commented 4 months ago
 publish(_: any, res: any) {
    if (typeof res?.contentType === "function") res.contentType("text");
    if (typeof res?.status === "function") res.status(200);

    return res?.json({
      key: this.publicKey("public"),
      format: "public",
    });
  }

the contentType must be an valid MediaType: https://www.iana.org/assignments/media-types/media-types.xhtml