2017-08-31 16:35:19 +00:00
|
|
|
from hosting.models import UserHostingKey
|
|
|
|
|
|
|
|
|
|
|
|
def get_all_public_keys(customer):
|
|
|
|
"""
|
|
|
|
Returns all the public keys of the user
|
|
|
|
:param customer: The customer whose public keys are needed
|
|
|
|
:return: A list of public keys
|
|
|
|
"""
|
2017-09-04 21:59:12 +00:00
|
|
|
return UserHostingKey.objects.filter(user_id=customer.id).values_list(
|
|
|
|
"public_key", flat=True)
|