@crossdelta/infrastructure 0.11.1 → 0.11.2

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.cjs CHANGED
@@ -1149,7 +1149,8 @@ var indent = (text, level) => {
1149
1149
  `).map((line) => line.trim() === "" ? "" : `${prefix}${line}`).join(`
1150
1150
  `);
1151
1151
  };
1152
- var basicAuthLines = (basicAuth) => basicAuth ? ["basicauth {", ` ${basicAuth.user} ${basicAuth.hash}`, "}"] : [];
1152
+ var encodeHash = (hash) => hash.startsWith("$") ? Buffer.from(hash).toString("base64") : hash;
1153
+ var basicAuthLines = (basicAuth) => basicAuth ? ["basic_auth {", ` ${basicAuth.user} ${encodeHash(basicAuth.hash)}`, "}"] : [];
1153
1154
  var generateHandleBlock = (handle, level, basicAuth) => {
1154
1155
  const hasPath = handle.path != null;
1155
1156
  const header = hasPath ? `handle ${handle.path}* {` : "handle {";
package/dist/index.js CHANGED
@@ -1053,7 +1053,8 @@ var indent = (text, level) => {
1053
1053
  `).map((line) => line.trim() === "" ? "" : `${prefix}${line}`).join(`
1054
1054
  `);
1055
1055
  };
1056
- var basicAuthLines = (basicAuth) => basicAuth ? ["basicauth {", ` ${basicAuth.user} ${basicAuth.hash}`, "}"] : [];
1056
+ var encodeHash = (hash) => hash.startsWith("$") ? Buffer.from(hash).toString("base64") : hash;
1057
+ var basicAuthLines = (basicAuth) => basicAuth ? ["basic_auth {", ` ${basicAuth.user} ${encodeHash(basicAuth.hash)}`, "}"] : [];
1057
1058
  var generateHandleBlock = (handle, level, basicAuth) => {
1058
1059
  const hasPath = handle.path != null;
1059
1060
  const header = hasPath ? `handle ${handle.path}* {` : "handle {";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crossdelta/infrastructure",
3
- "version": "0.11.1",
3
+ "version": "0.11.2",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "publishConfig": {