Commit d55d473e authored by Sven Franck's avatar Sven Franck

removed plumb regex, switch to call (parent) and delegate (child)

parent e6d89778
...@@ -1165,7 +1165,6 @@ ...@@ -1165,7 +1165,6 @@
ss_regexp = /^browser:\/\/sessionstorage\/([\w\W]+)/, ss_regexp = /^browser:\/\/sessionstorage\/([\w\W]+)/,
browse_ss_file_regexp = /^browser:\/\/browse\/ss\/([\w\W]+)/, browse_ss_file_regexp = /^browser:\/\/browse\/ss\/([\w\W]+)/,
browse_ss_directory_regexp = /^browser:\/\/browse\/ss\//, browse_ss_directory_regexp = /^browser:\/\/browse\/ss\//,
plumb_regexp = /^browser:\/\/plumb\/([\w\W]+)\//,
// internal API (scope, interaction are optional) // internal API (scope, interaction are optional)
// child > parent = call/{method}/{scope}/{interaction}/ // child > parent = call/{method}/{scope}/{interaction}/
...@@ -1259,23 +1258,6 @@ ...@@ -1259,23 +1258,6 @@
'Content-Type': 'application/hal+json' 'Content-Type': 'application/hal+json'
}, JSON.stringify(response)); }, JSON.stringify(response));
} else if (plumb_regexp.test(this.url)) {
console.log("PLUMB");
key = plumb_regexp.exec(this.url)[1];
if (this.method === "POST") {
if (key === "parentwindow") {
// as before...
window.parent.postMessage(this.requestBody, "*");
this.respond(204, {}, "");
} else {
this.respond(404, {}, "");
}
} else {
this.respond(405, {}, "");
}
// this looks up requests inside renderJs and // this looks up requests inside renderJs and
// triggers the respective postMessage // triggers the respective postMessage
// should we use the key here or not and maybe pass the scope // should we use the key here or not and maybe pass the scope
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment