2020-08-06 09:51:06 +00:00
|
|
|
class UserDrop < BaseDrop
|
2020-08-13 19:17:24 +00:00
|
|
|
def available_name
|
|
|
|
@obj.try(:available_name)
|
|
|
|
end
|
2022-12-23 10:06:11 +00:00
|
|
|
|
|
|
|
def first_name
|
|
|
|
@obj.try(:name).try(:split, ' ').try(:first)
|
|
|
|
end
|
|
|
|
|
|
|
|
def last_name
|
|
|
|
@obj.try(:name).try(:split, ' ').try(:last) if @obj.try(:name).try(:split, ' ').try(:size) > 1
|
|
|
|
end
|
2020-08-06 09:51:06 +00:00
|
|
|
end
|