MCPcopy Index your code
hub / github.com/ClearURLs/Addon / put

Method put

core_js/utils/Multimap.js:52–65  ·  view source on GitHub ↗
(key, value)

Source from the content-addressed store, hash-verified

50 }
51 }
52 put(key, value) {
53 let values = this._map.get(key);
54 if (!values) {
55 values = new Set();
56 }
57 const count = values.size;
58 values.add(value);
59 if (values.size === count) {
60 return false;
61 }
62 this._map.set(key, values);
63 this._size++;
64 return true;
65 }
66 has(key) {
67 return this._map.has(key);
68 }

Callers 2

constructorMethod · 0.80
appendMethod · 0.80

Calls 2

addMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected