$isPinned
Returns `true` if the message has been pinned to a channel in a guild the bot can see. Otherwise, the function returns `false`.

FUNCTION USAGE

  • $isPinned[channelID;messageID]

Properties:

channelID - Channel ID of the channel where the message is located. messageID - Message ID of the message being checked for being pinned to the channel.

Example 1: Returning true or false if the message is pinned to the current channel

1
bot.Command({
2
name: "pin-stat",
3
code: `
4
$isPinned[$channelID[];$message[1]]
5
`
6
})
Copied!

Example 2: Returning true or false if the message is pinned to another channel

1
bot.Command({
2
name: "pin-stat",
3
code: `
4
$isPinned[$findChannel[$message[1];$messageSlice[>1]]
5
`
6
})
Copied!
Last modified 4mo ago
Copy link
Contents
Properties: