diff --git a/blueprints/patch-legacy-reply.lua b/blueprints/patch-legacy-reply.lua new file mode 100644 index 00000000..d17eb910 --- /dev/null +++ b/blueprints/patch-legacy-reply.lua @@ -0,0 +1,13 @@ +local function patchReply(msg) + if not msg.reply then + msg.reply = function (replyMsg) + replyMsg.Target = msg["Reply-To"] or (replyMsg.Target or msg.From) + replyMsg["X-Reference"] = msg["X-Reference"] or msg.Reference or "" + replyMsg["X-Origin"] = msg["X-Origin"] or "" + + return ao.send(replyMsg) + end + end +end + +Handlers.prepend("_patch_reply", function (msg) return "continue" end, patchReply) \ No newline at end of file diff --git a/src/commands/os.js b/src/commands/os.js index 9247dd21..792a4161 100644 --- a/src/commands/os.js +++ b/src/commands/os.js @@ -76,6 +76,10 @@ _G.package.loaded[".${mod}"] = load_${mod.replace("-", "_")}() ` } +function patch3() { + +} + function patch2() { return ` Handlers.prepend("Assignment-Check", function (msg)