# -*- coding: utf-8 -*-
import os

os_env = os.environ


class Config(object):
    SECRET_KEY = os_env.get('INSPECTORS_SECRET', 'secret-key')  # TODO: Change me
    SQLALCHEMY_DATABASE_URI = os_env['DATABASE_URI']
    APP_DIR = os.path.abspath(os.path.dirname(__file__))  # This directory
    PROJECT_ROOT = os.path.abspath(os.path.join(APP_DIR, os.pardir))
    BCRYPT_LOG_ROUNDS = 13
    ASSETS_DEBUG = False
    DEBUG_TB_ENABLED = False  # Disable Debug toolbar
    DEBUG_TB_INTERCEPT_REDIRECTS = False
    CACHE_TYPE = 'simple'  # Can be "memcached", "redis", etc.


class ProdConfig(Config):
    """Production configuration."""
    ENV = 'prod'
    DEBUG = False
    SQLALCHEMY_DATABASE_URI = os_env.get('DATABASE_URI',
            'postgresql://localhost/mdc_inspectors')
    DEBUG_TB_ENABLED = False  # Disable Debug toolbar


class DevConfig(Config):
    """Development configuration."""
    ENV = 'dev'
    DEBUG = True
    SQLALCHEMY_DATABASE_URI = os_env.get('DATABASE_URI',
            'postgresql://localhost/mdc_inspectors')
    DEBUG_TB_ENABLED = True
    ASSETS_DEBUG = True  # Don't bundle/minify static assets
    CACHE_TYPE = 'simple'  # Can be "memcached", "redis", etc.


class TestConfig(Config):
    TESTING = True
    DEBUG = True
    SQLALCHEMY_DATABASE_URI = 'sqlite://'
    BCRYPT_LOG_ROUNDS = 1  # For faster tests
    WTF_CSRF_ENABLED = False  # Allows form testing

@@ -172,33 +172,33 @@
 HEMY_DATABASE_UR
-I
+L
  = os_env%5B'DATAB
@@ -203,17 +203,17 @@
 ABASE_UR
-I
+L
 '%5D%0A    A
@@ -678,33 +678,33 @@
 HEMY_DATABASE_UR
-I
+L
  = os_env.get('D
@@ -705,33 +705,33 @@
 get('DATABASE_UR
-I
+L
 ',%0A            '
@@ -947,17 +947,17 @@
 ABASE_UR
-I
+L
  = os_en
@@ -974,17 +974,17 @@
 ABASE_UR
-I
+L
 ',%0A     
@@ -1273,17 +1273,17 @@
 ABASE_UR
-I
+L
  = 'sqli

use DATABASE_URL not DATABASE_URI