How to read/write from/to ObjectStore. Is this below methods correct ?

def load_items(self):
        if self.algorithm.ObjectStore.ContainsKey(self.trade_planning_key):
            items_json = self.algorithm.ObjectStore.ReadBytes(self.trade_planning_key)
            return json.loads(items_json.decode("utf-8"), object_hook=self.deserialize_date)
        return []

    def store_items(self):
        items_json = json.dumps(self.items, default=self.serialize_date).encode("utf-8")
        self.algorithm.ObjectStore.SaveBytes(self.trade_planning_key, items_json)
        self.algorithm.Debug(f"Stored {len(self.items)} items in ObjectStore under tag '{self.trade_planning_key}'.")