خرید بک لینک

Vote count: 0

I'm a little confused by this error on the server. Exception while invoking method 'slingshotUploadFile' TypeError: Object [object Object] has no method 'getParam' The error appears to be related to var id = FlowRouter.getParam('id'); however when I console.log(id) it prints the correct id. Is FlowRouter.getParam('id'); not suppose to be used in a method?

Meteor.methods({
  slingshotUploadFile: function( url ) {
    check(url, String);
    var id = FlowRouter.getParam('id');

    try {
      Files.insert({
        url: url,
        userId: id,
        added: new Date() 
      });
    } catch( exception ) {
      retu exception;
    }
  }
});

asked 22 secs ago

- - , .
.

برچسب: نویسنده: استخدام کار تاريخ: جمعه 25 تير 1395 ساعت: 9:00

صفحه بندی