MCPcopy Index your code
hub / github.com/FThompson/FormPersistence.js / pushToArray

Function pushToArray

form-persistence.js:124–129  ·  view source on GitHub ↗

* Add a value to an object, creating an array to place it in if needed.

(dict, key, value)

Source from the content-addressed store, hash-verified

122 * Add a value to an object, creating an array to place it in if needed.
123 */
124 function pushToArray(dict, key, value) {
125 if (!(key in dict)) {
126 dict[key] = []
127 }
128 dict[key].push(value)
129 }
130
131 /**
132 * Checks if the given name should be filtered out.

Callers 1

serializeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected