Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const LOCAL_FILE_ROUTE = `${staticRoute}/avatars`;
const Stars = require('./custom-fields/Stars');
const getYear = require('date-fns/get_year');
// TODO: Make this work again
// const SecurePassword = require('./custom-fields/SecurePassword');
const { MongooseAdapter } = require('@keystonejs/adapter-mongoose');
const keystone = new Keystone({
name: 'Cypress Test Project Basic',
adapter: new MongooseAdapter(),
});
const fileAdapter = new LocalFileAdapter({
src: LOCAL_FILE_SRC,
path: LOCAL_FILE_ROUTE,
});
let embedAdapter;
if (process.env.NODE_ENV === 'test') {
embedAdapter = new MockOEmbedAdapter();
} else if (iframely.apiKey) {
embedAdapter = new IframelyOEmbedAdapter({ apiKey: iframely.apiKey });
}
let cloudinaryAdapter;
try {
cloudinaryAdapter = new CloudinaryAdapter({
...cloudinary,