mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 04:34:06 -08:00
⚡ Minor improvements to Slack-Node
This commit is contained in:
parent
025272953e
commit
2c834ef9c4
|
@ -15,6 +15,11 @@ export const messageOperations = [
|
|||
},
|
||||
},
|
||||
options: [
|
||||
{
|
||||
name: 'Delete',
|
||||
value: 'delete',
|
||||
description: 'Deletes a message',
|
||||
},
|
||||
{
|
||||
name: 'Get Permalink',
|
||||
value: 'getPermalink',
|
||||
|
@ -33,12 +38,7 @@ export const messageOperations = [
|
|||
{
|
||||
name: 'Update',
|
||||
value: 'update',
|
||||
description: 'Updates a message.',
|
||||
},
|
||||
{
|
||||
name: 'Delete',
|
||||
value: 'delete',
|
||||
description: 'Deletes a message.',
|
||||
description: 'Updates a message',
|
||||
},
|
||||
],
|
||||
default: 'post',
|
||||
|
@ -1711,7 +1711,7 @@ export const messageFields = [
|
|||
},
|
||||
{
|
||||
displayName: 'Timestamp',
|
||||
name: 'ts',
|
||||
name: 'timestamp',
|
||||
type: 'string',
|
||||
required: true,
|
||||
default: '',
|
||||
|
|
|
@ -798,10 +798,10 @@ export class Slack implements INodeType {
|
|||
//https://api.slack.com/methods/chat.delete
|
||||
if (operation === 'delete') {
|
||||
const channel = this.getNodeParameter('channelId', i) as string;
|
||||
const ts = this.getNodeParameter('ts', i) as string;
|
||||
const timestamp = this.getNodeParameter('timestamp', i) as string;
|
||||
const body: IDataObject = {
|
||||
channel,
|
||||
ts,
|
||||
ts: timestamp,
|
||||
};
|
||||
// Add all the other options to the request
|
||||
responseData = await slackApiRequest.call(this, 'POST', '/chat.delete', body, qs);
|
||||
|
|
Loading…
Reference in a new issue