Docker

Write an awesome doc for Docker, Docker Compose, and everything else in this domain. You can find invaluable examples and explanations here. I am trying to keep it up to date and relevant too. BTW if you also have a cool idea, or example open a PR/issue/discussion.

View on GitHub

MongoDB Playground

Unset a nullable Field

  1. await MetadataModel.findOneAndUpdate(
      { _id: metadata._id },
      { $unset: { taskId: 1 }, someOtherField: "value" },
    );
    
  2. const metadata = await MetadataModel.findById(metadata._id);
    if (data) {
      data.taskId = undefined;
      data.someOtherField = "value";
      await data.save();
    }