willwade
willwade

Reputation: 2220

"config should have required property 'media_folder'" - when it does

Its been a while since I've played with netlifycms - and I feel I've had this problem before but can't find the answer. My config.yml has the media_folder in it - but I'm getting an error it can't find a config setting for one - anyone have any ideas? So this is my config (full file

backend:
  name: github
  repo: acecentre/nhs-service-finder
  branch: master 

collections:
  - name: "nhs-service" 
    label: "Service" 
    folder: "content/ccg" 
    media_folder: "static/images/uploads"
    media_library:
      name: uploads    
    create: false 

But on loading the page (here) I get

Config Errors:
config should have required property 'media_folder'
config should have required property 'media_library'
config should match some schema in anyOf
Check your config.yml file.

What am I doing wrong?

Upvotes: 2

Views: 1798

Answers (1)

willwade
willwade

Reputation: 2220

Well - It took me a while.. media_folder and media_library - should be a root setting - not in collections..

backend:
  name: github
  repo: acecentre/nhs-service-finder
  branch: master 

media_folder: "static/images/uploads"
media_library:
   name: uploads

collections:
  - name: "nhs-service" 
    label: "Service" 
    folder: "content/ccg"   

Upvotes: 2

Related Questions