🔒 Enables sensetive data to be passed by env var

This commit is contained in:
Alicia Sykes
2024-04-14 20:50:03 +01:00
parent 75f65de8f6
commit 25e774ca79
26 changed files with 54 additions and 51 deletions

View File

@@ -113,7 +113,7 @@ export default {
},
computed: {
hostname() {
return this.options.hostname || widgetApiEndpoints.anonAddy;
return this.parseAsEnvVar(this.options.hostname) || widgetApiEndpoints.anonAddy;
},
apiVersion() {
return this.options.apiVersion || 'v1';
@@ -132,7 +132,7 @@ export default {
},
apiKey() {
if (!this.options.apiKey) this.error('An apiKey is required');
return this.options.apiKey;
return this.parseAsEnvVar(this.options.apiKey);
},
hideMeta() {
return this.options.hideMeta;