MCPcopy Create free account
hub / github.com/hydro-dev/Hydro / diffArray

Function diffArray

framework/utils/lib/common.ts:52–60  ·  view source on GitHub ↗
(a, b)

Source from the content-addressed store, hash-verified

50};
51
52export function diffArray(a, b) {
53 if (a.length !== b.length) return true;
54 a.sort();
55 b.sort();
56 for (const i in a) {
57 if (a[i] !== b[i]) return true;
58 }
59 return false;
60}
61
62export function formatDate(date: Date, fmt = '%Y-%m-%d %H:%M:%S') {
63 let m = (date.getMonth() + 1).toString();

Callers 1

postUpdateMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected