Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
feudal
feudalBackend
Commits
b1f6b7f6
Commit
b1f6b7f6
authored
Dec 15, 2017
by
Lukas Burgey
Browse files
Remove outcommented method
parent
47d4dda5
Changes
1
Hide whitespace changes
Inline
Side-by-side
django_backend/backend/models.py
View file @
b1f6b7f6
...
@@ -171,19 +171,6 @@ class SSHPublicKey(models.Model):
...
@@ -171,19 +171,6 @@ class SSHPublicKey(models.Model):
return
self
.
name
return
self
.
name
# finally delete the key if all the deployments are withdrawn
# and the withdrawal was seen by all clients
# @receiver(m2m_changed, sender=SSHPublicKey)
# def delete_withdrawn_ssh_key(
# sender, instance=None, created=False, **kwargs):
#
# if (instance.deleted
# and not instance.deployments.exists()
# and not instance.withdrawn_deployments.exists()):
# # TODO this does not work (see the m2m_changed signal doc)
# instance.delete()
class
Deployment
(
models
.
Model
):
class
Deployment
(
models
.
Model
):
user
=
models
.
ForeignKey
(
user
=
models
.
ForeignKey
(
User
,
User
,
...
@@ -249,7 +236,3 @@ class Deployment(models.Model):
...
@@ -249,7 +236,3 @@ class Deployment(models.Model):
deployment_change
.
send
(
sender
=
self
.
__class__
,
instance
=
self
)
deployment_change
.
send
(
sender
=
self
.
__class__
,
instance
=
self
)
# @receiver(post_save, sender=Deployment)
# def publish_deployment_creation(
# sender, instance=None, created=False, **kwargs):
# instance.send_change()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment