Fix first_name and last_name not being called if they are callable

This commit is contained in:
Dan 2019-01-11 13:02:19 +01:00
parent 161ab79eb3
commit 200ed844fe

View File

@ -578,13 +578,13 @@ class Client(Methods, BaseClient):
if not phone_registered:
self.first_name = (
input("First name: ") if self.first_name is None
else str(self.first_name) if callable(self.first_name)
else str(self.first_name()) if callable(self.first_name)
else str(self.first_name)
)
self.last_name = (
input("Last name: ") if self.last_name is None
else str(self.last_name) if callable(self.last_name)
else str(self.last_name()) if callable(self.last_name)
else str(self.last_name)
)