diff --git a/7-bank-project/api/server.js b/7-bank-project/api/server.js index 7a369fb6..af114ea1 100644 --- a/7-bank-project/api/server.js +++ b/7-bank-project/api/server.js @@ -27,7 +27,7 @@ const db = { const app = express(); app.use(bodyParser.urlencoded({ extended: true })); app.use(bodyParser.json()); -app.use(cors({ origin: /http:\/\/localhost/ })); +app.use(cors({ origin: /http:\/\/(127(\.\d){3}|localhost)/})); app.options('*', cors()); // ***************************************************************************