Skip to content

Latest commit

 

History

History
36 lines (24 loc) · 1.64 KB

allChannelGhosts.md

File metadata and controls

36 lines (24 loc) · 1.64 KB

About $allChannelGhosts (New Project 3 Command)

Get the hidden (deleted with $deleteQuestion) questions that are in the database but not in the channel. Instructor only.

Note: does not find zombies. To uncover zombies, use the $unearthZombies command.

Zombies are questions that were manually deleted from the channel. They need to be
assigned new message IDs in order to be restored--that is, they need to be reposted.
Ghosts are questions that were deleted (or hidden) with the deleteQuestion command.
Because their message IDs remain the same, their contents can be unhidden.

Changes

This command was introduced by CSC510-Group-25.

Location of Code

The code that implements the above mentioned functionality is located in cogs/qanda.py.

Code Description

Functions

channelGhostQs(self, ctx):
This function takes as arguments the values provided by the constructor through self and context in which the command was called.

How to run it? (Small Example)

You are in the server that has the Classmate Bot active and online. You go to the #q-and-a channel and enter the command $allChannelGhosts.

$allChannelGhosts

Successful execution of this command will DM all hidden questions and their answers to the user.