const databaseName = 'node-security';

module.exports = {
  development: {
    client: 'pg',
    connection: `${process.env.CONNECTIONSTRING}/${databaseName}`,
    debug: false,
    pool: {
      min: 1,
      max: 2
    },
    migrations: {
      directory: __dirname + '/server/db/migrations'
    },
    seeds: {
      directory: __dirname + '/server/db/seeds'
    }
  },
  test: {
    client: 'pg',
    connection: `${process.env.CONNECTIONSTRING}/${databaseName}_test`,
    migrations: {
      directory: __dirname + '/server/db/migrations'
    },
    seeds: {
      directory: __dirname + '/server/db/seeds'
    }
  },
  production : {
    client: 'pg',
    connection: `${process.env.CONNECTIONSTRING}/${databaseName}`,
    debug: false,
    pool: {
      min: 1,
      max: 2
    },
    migrations: {
      directory: __dirname + '/server/db/migrations'
    },
    seeds: {
      directory: __dirname + '/server/db/seeds'
    }
  },
};
@@ -1,43 +1,4 @@
-const databaseName = 'node-security';%0A%0A
 modu
@@ -55,35 +55,32 @@
     connection: 
-%60$%7B
 process.env.CONN
@@ -79,42 +79,20 @@
 env.
-CONNECTIONSTRING%7D/$%7BdatabaseName%7D%60
+DATABASE_URL
 ,%0A  
@@ -379,32 +379,16 @@
 NSTRING%7D
-/$%7BdatabaseName%7D
 _test%60,%0A
@@ -580,35 +580,32 @@
     connection: 
-%60$%7B
 process.env.CONN
@@ -604,42 +604,20 @@
 env.
-CONNECTIONSTRING%7D/$%7BdatabaseName%7D%60
+DATABASE_URL
 ,%0A  

use env to get connectionstring