Skip to content

Commit

Permalink
Fixed an unexpected server in non-worker FlowStreams (critical).
Browse files Browse the repository at this point in the history
  • Loading branch information
petersirka committed Apr 12, 2024
1 parent 91d34df commit f3c2d6d
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions flow-flowstream.js
Original file line number Diff line number Diff line change
Expand Up @@ -2699,14 +2699,17 @@ function MAKEFLOWSTREAM(meta) {
};

flow.proxy.refreshmeta = function() {

flow.origin = flow.$schema.origin;
flow.proxypath = flow.$schema.proxypath || '';

if (flow.proxypath) {
if (!F.server)
F.httpload({ unixsocket: flow.$schema.unixsocket });
} else if (F.server)
F.server.close();
if (isFLOWSTREAMWORKER) {
if (flow.proxypath) {
if (!F.server)
F.httpload({ unixsocket: flow.$schema.unixsocket });
} else if (F.server)
F.server.close();
}

flow.cloning = flow.$schema.cloning != false;
flow.proxy.send(makemeta(), 0);
Expand Down

0 comments on commit f3c2d6d

Please sign in to comment.