You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: exist_LFP.m
    path of file: ./repos/CellExplorer/calc_CellMetrics
    
    the code of the file until where you have to start completion: function lfpExtension = exist_LFP(session)
% Checks for an existing LFP file
%
% By Peter Petersen
% petersen.peter@gmail.com
% Last edited: 12-11-2019


    
function lfpExtension = exist_LFP(session)
% Checks for an existing LFP file
%
% By Peter Petersen
% petersen.peter@gmail.com
% Last edited: 12-11-2019

basepath = session.general.basePath;
basename = session.general.name;
if ~exist(fullfile(basepath, [basename, '.lfp']),'file') && ~exist(fullfile(basepath, [basename, '.eeg']),'file')
    disp('Creating lfp file')
    ce_LFPfromDat(session,'noPrompts',true)
    lfpExtension = '.lfp';
elseif exist(fullfile(basepath, [basename, '.lfp']),'file')
    lfpExtension = '.lfp';
elseif exist(fullfile(basepath, [basename, '.eeg']),'file')
    lfpExtension = '.eeg';
end