svoid dm_moduleLibraryComments_mergeFromRemote(S computerID) { L lRemote = dm_remote_callModule_safeRestruct(computerID, dm_remote_requireModule(computerID, "#1019617/ModuleLibraryComments"), 'concepts); print("Got " + n2(lRemote, "remote entry", "remote entries")); O module = dm_requireModule("#1019617/ModuleLibraryComments"); for (O o : lRemote) { S snippetID = getString(o, 'snippetID); if (empty(snippetID)) continue; S rComment = getString(o, 'comment); if (nempty(rComment)) { S comment = dm_call(module, 'getComment, snippetID); if (nempty(comment) && neq(rComment, comment)) print("Conflict for snippet ID: " + snippetID); else if (empty(comment)) { dm_call(module, 'setComment, snippetID, rComment); print("Set comment for " + snippetID); } } S rForPublic = getString(o, 'forPublic); if (nempty(rForPublic)) { S forPublic = dm_call(module, 'getForPublic, snippetID); if (nempty(forPublic) && neq(rForPublic, forPublic)) print("Conflict for snippet ID: " + snippetID); else if (empty(forPublic)) { dm_call(module, 'setForPublic, snippetID, rForPublic); print("Set for-public value for " + snippetID); } } } }