On the nuclearity of integral operators