Gitiles
Code Review
Sign In
gerrit.opencord.org
/
xos
/
b5885408f6b047c714c015c5f6a36e1a692e88d7
/
.
/
planetstack
/
observer
/
deleters
/
user_deleter.py
blob: f2509939f156fbb6bf701b9b5110e49569ebb805 [
file
] [
log
] [
blame
]
from
core
.
models
import
User
from
observer
.
deleter
import
Deleter
class
UserDeleter
(
Deleter
):
model
=
'User'
def
call
(
self
,
pk
):
user
=
User
.
objects
.
get
(
pk
=
pk
)
if
user
.
kuser_id
:
self
.
driver
.
delete_user
(
user
.
kuser_id
)
user
.
delete
()