define __repr__ for the Availability API class
This commit is contained in:
parent
16b9bdd7f9
commit
66e16d6d89
@ -36,6 +36,9 @@ class WaybackMachineAvailabilityAPI:
|
|||||||
def unix_timestamp_to_wayback_timestamp(self, unix_timestamp):
|
def unix_timestamp_to_wayback_timestamp(self, unix_timestamp):
|
||||||
return datetime.utcfromtimestamp(int(unix_timestamp)).strftime("%Y%m%d%H%M%S")
|
return datetime.utcfromtimestamp(int(unix_timestamp)).strftime("%Y%m%d%H%M%S")
|
||||||
|
|
||||||
|
def __repr__(self):
|
||||||
|
return str(self) # self.__str__()
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
if not self.JSON:
|
if not self.JSON:
|
||||||
return None
|
return None
|
||||||
|
Loading…
Reference in New Issue
Block a user