|
|
|
@ -8,9 +8,10 @@ const storeController = require("./controllers/storeController.js")
|
|
|
|
|
const boom = require("boom");
|
|
|
|
|
const bcrypt = require('bcrypt');
|
|
|
|
|
const { ProfilePictureStore,generateinstallationId,Store} = require("./models/store");
|
|
|
|
|
const cors = require('fastify-cors');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const cors = require("cors");
|
|
|
|
|
//const cors = require("cors");
|
|
|
|
|
const swagger = require("./config/swagger");
|
|
|
|
|
const rawBody = require('raw-body')
|
|
|
|
|
const uuidv4 = require("uuid").v4;
|
|
|
|
@ -25,6 +26,10 @@ const fastify = require("fastify")({
|
|
|
|
|
|
|
|
|
|
// const Fastify = require("fastify");
|
|
|
|
|
|
|
|
|
|
fastify.register(cors, {
|
|
|
|
|
origin: 'http://localhost:3001', // Allow only your frontend URL
|
|
|
|
|
methods: ['GET', 'POST', 'PUT', 'DELETE'], // Allowed HTTP methods
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// const Fastify = require("fastify");
|
|
|
|
|