human
Solve the following python programming problem given the following code:
def last_heartbeat() : 
    def _date_or_none(val) : 
        if (val and (val != NOT_FOUND) and (val != NOT_CONFIGURED)) : 
            return datetime.strptime (val, DATE_FORMAT) 
return None 
from_file = _date_or_none (get_file_heartbeat ()) 
    from_cache = _date_or_none (get_cache_heartbeat ()) 
    if (from_file and from_cache) : 
        return (_date_or_none if (from_file > from_cache) else from_cache) 
else : 
        if from_file : 
            return from_file 
else : 
            if from_cache : 
                return from_cache 
else : 
                return None 

    
    

    Fix the buggy line: return (_date_or_none if (from_file > from_cache) else from_cache)
assistant
#Here is Python program to fix the buggy line: return (_date_or_none if (from_file > from_cache) else from_cache)
.

return (from_file if (from_file > from_cache) else from_cache)