fixed bug whle fetching emails