mirror of
https://github.com/zulip/zulip.git
synced 2025-11-05 06:23:38 +00:00
realm/playground: Add API endpoint for deleting a playground entry.
Similar to the previous commit, we have added a `do_*` function
which does the deletion from the DB. The next commit handles sending
the events when both adding and deleting a playground entry.
Added the openAPI format data to zulip.yaml for DELETE
/realm/playgrounds/{playground_id}. Also added python and curl
examples to remove-playground.md.
Tests added.
This commit is contained in:
@@ -6602,6 +6602,10 @@ def do_add_realm_playground(realm: Realm, **kwargs: Any) -> int:
|
||||
return realm_playground.id
|
||||
|
||||
|
||||
def do_remove_realm_playground(realm_playground: RealmPlayground) -> None:
|
||||
realm_playground.delete()
|
||||
|
||||
|
||||
def get_occupied_streams(realm: Realm) -> QuerySet:
|
||||
# TODO: Make a generic stub for QuerySet
|
||||
""" Get streams with subscribers """
|
||||
|
||||
Reference in New Issue
Block a user