wechat-api icon indicating copy to clipboard operation
wechat-api copied to clipboard

updateMatieral有错

Open vectorZou opened this issue 10 years ago • 4 comments

exports.updateNewsMaterial = function (news, callback) { this.preRequest(this._uploadNewsMaterial, arguments); };

/*!

  • 新增永久图文素材的未封装版本 */ // 这里的地址有错/add_news?access_token应该是update_news吧 exports._updateNewsMaterial = function (news, callback) { var url = this.prefix + 'material/add_news?access_token=' + this.token.accessToken; this.request(url, postJSON(news), wrapper(callback)); };

vectorZou avatar Aug 17 '15 10:08 vectorZou

now i pretty sure this is a bug for updateMaterial function. is it you want to do this?

vectorZou avatar Aug 17 '15 10:08 vectorZou

please report the api doc address. thank you.

JacksonTian avatar Aug 17 '15 13:08 JacksonTian

/lib/api_material.js line at 212 and 219

vectorZou avatar Aug 18 '15 01:08 vectorZou

@vectorZou 可以自己提一个pr学习一下,还有英文要加强哟 有空可以领个任务,把所有的API用以下形式重新封装一下:

make(exports, 'updateNewsMaterial', function (news, callback) {
  var url = this.prefix + 'material/update_news?access_token=' + this.token.accessToken;
  this.request(url, postJSON(news), wrapper(callback));
});

loulin avatar Sep 29 '15 08:09 loulin