MCPcopy Create free account
hub / github.com/Khan/perseus / statusFor

Function statusFor

packages/perseus-editor/src/diffs/shared/string-array-diff.ts:22–30  ·  view source on GitHub ↗
(chunk: ImageEntry)

Source from the content-addressed store, hash-verified

20};
21
22function statusFor(chunk: ImageEntry): ImageStatus {
23 if (chunk.added) {
24 return "added";
25 }
26 if (chunk.removed) {
27 return "removed";
28 }
29 return "unchanged";
30}
31
32// Turn a chunk (which contains an array of values and a status)
33// into an array of values, each with the same status

Callers 1

splitUpChunkFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected