blob: d76b5331546e89d54a3e49e0c9cc2cc4e0cab049 [file] [log] [blame]
Tony Mack387a73f2013-09-18 07:59:14 -04001from core.models import Sliver
2from observer.deleter import Deleter
3
4class SliverDeleter(Deleter):
5 model='Sliver'
6
7 def call(self, pk):
8 sliver = Sliver.objects.get(pk=pk)
9 if sliver.instance_id:
10 self.driver.destroy_instance(sliver.instance_id)
11 sliver.delete()