Email won't send if query result is empty. #1279