Skip to content

Commit

Permalink
Merge pull request #542 from aragon/fix/plugin-typo
Browse files Browse the repository at this point in the history
fix typo in fallback value
  • Loading branch information
jordaniza authored Feb 20, 2024
2 parents 959e1c1 + 90a2456 commit 22c6e60
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 3 additions & 3 deletions packages/contracts/test/deploy/default-env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ describe('detect network', () => {

it('sets the correct fallbacks for each environment variable', () => {
expect(daoDomainEnv(network)).to.equal('dao.eth');
expect(pluginDomainEnv(network)).to.equal('plugin.eth');
expect(pluginDomainEnv(network)).to.equal('plugin.dao.eth');
expect(managementDaoSubdomainEnv(network)).to.equal('management');
expect(managementDaoMultisigApproversEnv(network)).to.equal(
HARDHAT_ACCOUNTS[0].ADDRESS
Expand All @@ -63,8 +63,8 @@ describe('detect network', () => {
it('string interpolates the ENS subdomains', () => {
const network: Network = {name: 'FakeNet'} as unknown as Network;
process.env['FAKENET_DAO_ENS_DOMAIN'] = 'mydao.eth';
process.env['FAKENET_PLUGIN_ENS_DOMAIN'] = 'myplugin.eth';
process.env['FAKENET_PLUGIN_ENS_DOMAIN'] = 'myplugin.dao.eth';
expect(daoDomainEnv(network)).to.equal('mydao.eth');
expect(pluginDomainEnv(network)).to.equal('myplugin.eth');
expect(pluginDomainEnv(network)).to.equal('myplugin.dao.eth');
});
});
6 changes: 5 additions & 1 deletion packages/contracts/utils/environment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,11 @@ export const daoDomainEnv = (network: Network): string =>
env(network, `${network.name.toUpperCase()}_DAO_ENS_DOMAIN`, 'dao.eth');

export const pluginDomainEnv = (network: Network): string =>
env(network, `${network.name.toUpperCase()}_PLUGIN_ENS_DOMAIN`, 'plugin.eth');
env(
network,
`${network.name.toUpperCase()}_PLUGIN_ENS_DOMAIN`,
'plugin.dao.eth'
);

export const managementDaoSubdomainEnv = (network: Network): string =>
env(network, 'MANAGEMENT_DAO_SUBDOMAIN', 'management');
Expand Down

0 comments on commit 22c6e60

Please sign in to comment.