How do I update the data in an object that is in an array?

Make sure you have wrapped the query in async/await method, to wait for the response.

async function yourMethodName() {
  await message.user.updateOne(...
}