drawio-mcp-server
Version:
Provides Draw.io services to MCP Clients
15 lines (14 loc) • 396 B
JavaScript
/**
* Removes top-level fields from an object that start with '__'
* @param obj The input object to process
* @returns A new object with internal fields (starting with '__') removed
*/
export function strip_internal_fields(obj) {
const result = {};
for (const key in obj) {
if (!key.startsWith("__")) {
result[key] = obj[key];
}
}
return result;
}