I tried to add the upload feature to my Adminjs but I am getting the error:
TypeError: propertyPath.replace is not a function
I am using Mongoose
Here is my code:
const ImageResource = {
resource: FileModel,
features: [
uploadFeature({
provider: { aws: AWScredentials },
properties: {
key: {
type: 'string',
},
},
validation: { mimeTypes: ['image/*'] },
}),
],
}

Please can someone help me with this?