Merge branch '2019-deprecate_chat_sendMessage' of verdnatura/salix into dev
gitea/salix/dev This commit looks good
Details
gitea/salix/dev This commit looks good
Details
This commit is contained in:
commit
9d02b2fcaf
|
@ -1,30 +0,0 @@
|
||||||
module.exports = Self => {
|
|
||||||
Self.remoteMethodCtx('sendMessage', {
|
|
||||||
description: 'Send a RocketChat message',
|
|
||||||
accessType: 'WRITE',
|
|
||||||
accepts: [{
|
|
||||||
arg: 'to',
|
|
||||||
type: 'String',
|
|
||||||
required: true,
|
|
||||||
description: 'user (@) or channel (#) to send the message'
|
|
||||||
}, {
|
|
||||||
arg: 'message',
|
|
||||||
type: 'String',
|
|
||||||
required: true,
|
|
||||||
description: 'The message'
|
|
||||||
}],
|
|
||||||
returns: {
|
|
||||||
type: 'Object',
|
|
||||||
root: true
|
|
||||||
},
|
|
||||||
http: {
|
|
||||||
path: `/sendMessage`,
|
|
||||||
verb: 'POST'
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
// FIXME: Deprecate this method #2019
|
|
||||||
Self.sendMessage = async(ctx, to, message) => {
|
|
||||||
return Self.send(ctx, to, message);
|
|
||||||
};
|
|
||||||
};
|
|
|
@ -1,5 +1,4 @@
|
||||||
module.exports = Self => {
|
module.exports = Self => {
|
||||||
require('../methods/chat/send')(Self);
|
require('../methods/chat/send')(Self);
|
||||||
require('../methods/chat/sendMessage')(Self);
|
|
||||||
require('../methods/chat/sendCheckingPresence')(Self);
|
require('../methods/chat/sendCheckingPresence')(Self);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue