简体   繁体   中英

Meteor.Error Body cannot exceed 3000 characters

I am building a new application using Telescope , same as ProductHunt. I imported new feed post from other sites such as http://gigaom.com/feed/ , in the admin settings panel.

In the browser console I executed Meteor.call ('fetchFeeds') code to test the feed's. But the feeds are not importing showing error in command prompt.

*Error [ Body cannot exceed 3000 characters][400].
error.Type :' Meteor.Error'* 

How to overcome this please reply. It will be really helpfull. Thank you.

If you feeds content is more than 3000 words, it will give you that error, cause you have a validation set on the Posts object for max length of 3000. You can update the below code in telescope-posts package posts.js to whatever validation you want or even remove it to let any amount of data to be imported..

/**
    Post body (markdown)
  */
  body: {
    type: String,
    optional: true,
    max: 3000,
    editableBy: ["member", "admin"],
    autoform: {
      rows: 5
    }
  }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM