I\'m sure there\'s a simpler way of doing this that\'s just not occurring to me.
I\'m calling a bunch of methods that return a list. The list may be empty. If the
How about this:
(my_list and my_list[0]) or None
Note: This should work fine for lists of objects but it might return incorrect answer in case of number or string list per the comments below.