Skip to content

Latest commit

 

History

History
31 lines (20 loc) · 1.23 KB

deleteResource.md

File metadata and controls

31 lines (20 loc) · 1.23 KB

About $deleteResource

A command that lets the instructor delete a resource link of course materials. Instructor only.

Changes

This command was introduced by CSC510-Group-5.

Location of Code

The code that implements the above mentioned functionality is located in resource.py.

Code Description

Functions

deleteResource(ctx, topic, resource_link)::
This function takes as arguments the context in which the command was called, the name of the topic and the resource_link that needs to be discarded.

How to run it? (Small Example)

You are in the server that has the Classmate Bot active and online. You go to the #instructor-commands channel and enter the command $deleteResource topic_name resource_link.

$deleteResource "Testing" "https://github.com/txt/se23/blob/main/docs/testing1.md"

Successful execution of this command will delete the resource in the resource list.

This can be verified by the command $showAllResource to check whether the resource has been deleted.