Esempio n. 1
0
    def on_delete(self, request, response, id):
        """Delete a Group."""
        group = Session.query(Group).get(id)
        if group is None:
            raise HTTPNotFound

        Session.delete(group)
        response.status = HTTP_NO_CONTENT
Esempio n. 2
0
    def on_delete(self, request, response, email):
        """Delete a User."""
        user = Session.query(User).get(email)
        if user is None:
            raise HTTPNotFound

        Session.delete(user)
        response.status = HTTP_NO_CONTENT