# Upgraded forest-express from 6.1.0 --\> 6.1.2, now getting getting the "Cannot reach your database" error on production

**URL:** <https://community.forestadmin.com/t/upgraded-forest-express-from-6-1-0-6-1-2-now-getting-getting-the-cannot-reach-your-database-error-on-production/140>\
**Category:** Help me!\
**Created:** [May 11, 2020, 5:31pm UTC](https://community.forestadmin.com/t/upgraded-forest-express-from-6-1-0-6-1-2-now-getting-getting-the-cannot-reach-your-database-error-on-production/140 "2020-05-11T17:31:20Z")\
**Posts on this page:** 1\
**Showing post:** 11

<div class="post-metadata">

**Author:** ![Yoad\_Snapir](https://dub1.discourse-cdn.com/flex013/user_avatar/community.forestadmin.com/yoad_snapir/32/101_2.png) [@Yoad\_Snapir](https://community.forestadmin.com/u/Yoad_Snapir)\
**Post date:** [May 13, 2020, 6:40am UTC](https://community.forestadmin.com/t/upgraded-forest-express-from-6-1-0-6-1-2-now-getting-getting-the-cannot-reach-your-database-error-on-production/140/11 "2020-05-13T06:40:07Z")

</div>

Austin,  
I suspect this is all around the CORS errors.  
I recall Liana 6 has changed where the CORS middleware is being mounted and who’s responsibility is to do that (it used to be liana express, but I believe now it’s on the developer side).  
Another hint that his is the problem is that you said it’s on Production and not your local env.

Can you find in your code something similar to this:

```javascript
app.use(
  cors({
    origin: /forestadmin\.com$/,
    allowedHeaders: ['Authorization', 'X-Requested-With', 'Content-Type'],
    maxAge: 86400, // NOTICE: 1 day
    credentials: true,
  })
);

```

This should come before you mount the forest middleware which looks like this:

```javascript
app.use('/forest', (request, response, next) => {
...

```

Also not that to use `cors` you need to require it first:

```javascript
const cors = require('cors');

```

---

_[View the full topic](https://community.forestadmin.com/t/upgraded-forest-express-from-6-1-0-6-1-2-now-getting-getting-the-cannot-reach-your-database-error-on-production/140)._
