Skip to content

Commit

Permalink
Implement method to delete a pass by passTypeIdentifier and serialNumber
Browse files Browse the repository at this point in the history
  • Loading branch information
echoTraum committed Jul 20, 2024
1 parent 6bcf7e7 commit 1c817cc
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions passslot.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import os.path, logging, sys, time

try:
import ujson as json
except ImportError:
Expand Down Expand Up @@ -100,10 +102,6 @@ def update_pass_value(self, pspass, placeholderName, value):
resource = "/passes/%s/%s/values/%s" % (pspass.passTypeIdentifier, pspass.serialNumber, placeholderName)
content = {'value': value}
return self.__call('put', resource, content)

def delete_pass(self, pspass):
resource = "/passes/%s/%s" % (pspass.passTypeIdentifier, pspass.serialNumber)
return self.__call('delete', resource)

def __call(self, method, resource, content=None, multipart=False):

Expand Down

0 comments on commit 1c817cc

Please sign in to comment.