Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function assemble(str, cb) {
var opts = {importHook: importHook, reassignJavadoc: true};
avro.assemble('', opts, function (err, attrs) {
if (err) {
cb(err);
return;
}
// Make sure the protocol is valid.
try {
window.PROTOCOL = avro.parse(attrs, {wrapUnions: true});
} catch (parseErr) {
cb(parseErr);
return;
}
cb(null, attrs);
});
function importHook(path, kind, cb) {
if (path) {