Fixing config so it works propertly in prod and test modes