变量未在引号内正确解释

时间:2016-12-08 16:44:25

标签: node.js variables quotes double-quotes onesignal

  let adminIDs = _.map(Cause.admins, 'id');
  let message = {
    app_id: '**************',
    contents: {"en": "Yeah Buddy, Rolling Like a Big Shot!"},
    filters: [{"field": "tag", "key": "userId", "relation": "=", "value": adminIDs}]
  };

回复如下:

{ id: '',
  recipients: 0,
  errors: [ 'All included players are not subscribed' ] }

console.log(adminIDs); returns an ID value

在响应中,似乎过滤器中的“adminID”似乎没有从上面的变量“adminIDs”中读入。我是否需要在过滤器中做些什么来让它正确读取变量?谢谢!

0 个答案:

没有答案