@jaypie/constructs 1.2.64 → 1.2.65
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/cjs/index.cjs +8 -6
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/index.js +8 -6
- package/dist/esm/index.js.map +1 -1
- package/package.json +1 -1
package/dist/esm/index.js
CHANGED
|
@@ -1122,16 +1122,18 @@ class JaypieEnvSecret extends JaypieSecret {
|
|
|
1122
1122
|
super(scope, idOrEnvKey, props);
|
|
1123
1123
|
}
|
|
1124
1124
|
buildSecret(context) {
|
|
1125
|
-
const { envKey, id
|
|
1125
|
+
const { envKey, id } = context;
|
|
1126
1126
|
const props = context.props;
|
|
1127
1127
|
const { consumer = checkEnvIsConsumer$1(), export: exportParam, generateSecretString, provider = checkEnvIsProvider$1(), removalPolicy, roleTag, vendorTag, value, } = props;
|
|
1128
1128
|
let exportName;
|
|
1129
1129
|
if (!exportParam) {
|
|
1130
|
-
//
|
|
1131
|
-
//
|
|
1132
|
-
//
|
|
1133
|
-
//
|
|
1134
|
-
|
|
1130
|
+
// Always derive the export name from the construct id so the name is
|
|
1131
|
+
// stable across both call forms. For shorthand detection the id carries
|
|
1132
|
+
// the "EnvSecret_" prefix; for the explicit (id, { envKey }) form the id
|
|
1133
|
+
// is the caller's construct id. Deriving from envKey instead would change
|
|
1134
|
+
// the export name for an unchanged explicit-form call site across a
|
|
1135
|
+
// version bump and break existing cross-stack imports (issues #347, #365).
|
|
1136
|
+
const exportSource = id;
|
|
1135
1137
|
exportName = exportEnvName$1(exportSource, process.env, consumer);
|
|
1136
1138
|
}
|
|
1137
1139
|
else {
|