@rpgjs/vite 5.0.0-alpha.13 → 5.0.0-alpha.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +290 -488
- package/dist/index.js.map +1 -1
- package/dist/server-plugin.d.ts +1 -1
- package/package.json +2 -2
- package/src/server-plugin.ts +126 -28
package/dist/index.js
CHANGED
|
@@ -199,457 +199,89 @@ const rpgjsModuleViteConfig = () => {
|
|
|
199
199
|
});
|
|
200
200
|
};
|
|
201
201
|
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
var
|
|
205
|
-
|
|
206
|
-
var
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
charToInt[c] = i;
|
|
224
|
-
}
|
|
225
|
-
function decodeInteger(reader, relative) {
|
|
226
|
-
let value = 0;
|
|
227
|
-
let shift = 0;
|
|
228
|
-
let integer = 0;
|
|
229
|
-
do {
|
|
230
|
-
const c = reader.next();
|
|
231
|
-
integer = charToInt[c];
|
|
232
|
-
value |= (integer & 31) << shift;
|
|
233
|
-
shift += 5;
|
|
234
|
-
} while (integer & 32);
|
|
235
|
-
const shouldNegate = value & 1;
|
|
236
|
-
value >>>= 1;
|
|
237
|
-
if (shouldNegate) {
|
|
238
|
-
value = -2147483648 | -value;
|
|
239
|
-
}
|
|
240
|
-
return relative + value;
|
|
241
|
-
}
|
|
242
|
-
function encodeInteger(builder, num, relative) {
|
|
243
|
-
let delta = num - relative;
|
|
244
|
-
delta = delta < 0 ? (-delta << 1) | 1 : delta << 1;
|
|
245
|
-
do {
|
|
246
|
-
let clamped = delta & 0b011111;
|
|
247
|
-
delta >>>= 5;
|
|
248
|
-
if (delta > 0)
|
|
249
|
-
clamped |= 0b100000;
|
|
250
|
-
builder.write(intToChar[clamped]);
|
|
251
|
-
} while (delta > 0);
|
|
252
|
-
return num;
|
|
253
|
-
}
|
|
254
|
-
function hasMoreVlq(reader, max) {
|
|
255
|
-
if (reader.pos >= max)
|
|
256
|
-
return false;
|
|
257
|
-
return reader.peek() !== comma;
|
|
258
|
-
}
|
|
259
|
-
|
|
260
|
-
const bufLength = 1024 * 16;
|
|
261
|
-
// Provide a fallback for older environments.
|
|
262
|
-
const td = typeof TextDecoder !== 'undefined'
|
|
263
|
-
? /* #__PURE__ */ new TextDecoder()
|
|
264
|
-
: typeof Buffer !== 'undefined'
|
|
265
|
-
? {
|
|
266
|
-
decode(buf) {
|
|
267
|
-
const out = Buffer.from(buf.buffer, buf.byteOffset, buf.byteLength);
|
|
268
|
-
return out.toString();
|
|
269
|
-
},
|
|
270
|
-
}
|
|
271
|
-
: {
|
|
272
|
-
decode(buf) {
|
|
273
|
-
let out = '';
|
|
274
|
-
for (let i = 0; i < buf.length; i++) {
|
|
275
|
-
out += String.fromCharCode(buf[i]);
|
|
276
|
-
}
|
|
277
|
-
return out;
|
|
278
|
-
},
|
|
279
|
-
};
|
|
280
|
-
class StringWriter {
|
|
281
|
-
constructor() {
|
|
282
|
-
this.pos = 0;
|
|
283
|
-
this.out = '';
|
|
284
|
-
this.buffer = new Uint8Array(bufLength);
|
|
285
|
-
}
|
|
286
|
-
write(v) {
|
|
287
|
-
const { buffer } = this;
|
|
288
|
-
buffer[this.pos++] = v;
|
|
289
|
-
if (this.pos === bufLength) {
|
|
290
|
-
this.out += td.decode(buffer);
|
|
291
|
-
this.pos = 0;
|
|
292
|
-
}
|
|
293
|
-
}
|
|
294
|
-
flush() {
|
|
295
|
-
const { buffer, out, pos } = this;
|
|
296
|
-
return pos > 0 ? out + td.decode(buffer.subarray(0, pos)) : out;
|
|
297
|
-
}
|
|
298
|
-
}
|
|
299
|
-
class StringReader {
|
|
300
|
-
constructor(buffer) {
|
|
301
|
-
this.pos = 0;
|
|
302
|
-
this.buffer = buffer;
|
|
303
|
-
}
|
|
304
|
-
next() {
|
|
305
|
-
return this.buffer.charCodeAt(this.pos++);
|
|
306
|
-
}
|
|
307
|
-
peek() {
|
|
308
|
-
return this.buffer.charCodeAt(this.pos);
|
|
309
|
-
}
|
|
310
|
-
indexOf(char) {
|
|
311
|
-
const { buffer, pos } = this;
|
|
312
|
-
const idx = buffer.indexOf(char, pos);
|
|
313
|
-
return idx === -1 ? buffer.length : idx;
|
|
314
|
-
}
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
const EMPTY = [];
|
|
318
|
-
function decodeOriginalScopes(input) {
|
|
319
|
-
const { length } = input;
|
|
320
|
-
const reader = new StringReader(input);
|
|
321
|
-
const scopes = [];
|
|
322
|
-
const stack = [];
|
|
323
|
-
let line = 0;
|
|
324
|
-
for (; reader.pos < length; reader.pos++) {
|
|
325
|
-
line = decodeInteger(reader, line);
|
|
326
|
-
const column = decodeInteger(reader, 0);
|
|
327
|
-
if (!hasMoreVlq(reader, length)) {
|
|
328
|
-
const last = stack.pop();
|
|
329
|
-
last[2] = line;
|
|
330
|
-
last[3] = column;
|
|
331
|
-
continue;
|
|
332
|
-
}
|
|
333
|
-
const kind = decodeInteger(reader, 0);
|
|
334
|
-
const fields = decodeInteger(reader, 0);
|
|
335
|
-
const hasName = fields & 0b0001;
|
|
336
|
-
const scope = (hasName ? [line, column, 0, 0, kind, decodeInteger(reader, 0)] : [line, column, 0, 0, kind]);
|
|
337
|
-
let vars = EMPTY;
|
|
338
|
-
if (hasMoreVlq(reader, length)) {
|
|
339
|
-
vars = [];
|
|
340
|
-
do {
|
|
341
|
-
const varsIndex = decodeInteger(reader, 0);
|
|
342
|
-
vars.push(varsIndex);
|
|
343
|
-
} while (hasMoreVlq(reader, length));
|
|
344
|
-
}
|
|
345
|
-
scope.vars = vars;
|
|
346
|
-
scopes.push(scope);
|
|
347
|
-
stack.push(scope);
|
|
348
|
-
}
|
|
349
|
-
return scopes;
|
|
350
|
-
}
|
|
351
|
-
function encodeOriginalScopes(scopes) {
|
|
352
|
-
const writer = new StringWriter();
|
|
353
|
-
for (let i = 0; i < scopes.length;) {
|
|
354
|
-
i = _encodeOriginalScopes(scopes, i, writer, [0]);
|
|
355
|
-
}
|
|
356
|
-
return writer.flush();
|
|
357
|
-
}
|
|
358
|
-
function _encodeOriginalScopes(scopes, index, writer, state) {
|
|
359
|
-
const scope = scopes[index];
|
|
360
|
-
const { 0: startLine, 1: startColumn, 2: endLine, 3: endColumn, 4: kind, vars } = scope;
|
|
361
|
-
if (index > 0)
|
|
362
|
-
writer.write(comma);
|
|
363
|
-
state[0] = encodeInteger(writer, startLine, state[0]);
|
|
364
|
-
encodeInteger(writer, startColumn, 0);
|
|
365
|
-
encodeInteger(writer, kind, 0);
|
|
366
|
-
const fields = scope.length === 6 ? 0b0001 : 0;
|
|
367
|
-
encodeInteger(writer, fields, 0);
|
|
368
|
-
if (scope.length === 6)
|
|
369
|
-
encodeInteger(writer, scope[5], 0);
|
|
370
|
-
for (const v of vars) {
|
|
371
|
-
encodeInteger(writer, v, 0);
|
|
372
|
-
}
|
|
373
|
-
for (index++; index < scopes.length;) {
|
|
374
|
-
const next = scopes[index];
|
|
375
|
-
const { 0: l, 1: c } = next;
|
|
376
|
-
if (l > endLine || (l === endLine && c >= endColumn)) {
|
|
377
|
-
break;
|
|
378
|
-
}
|
|
379
|
-
index = _encodeOriginalScopes(scopes, index, writer, state);
|
|
380
|
-
}
|
|
381
|
-
writer.write(comma);
|
|
382
|
-
state[0] = encodeInteger(writer, endLine, state[0]);
|
|
383
|
-
encodeInteger(writer, endColumn, 0);
|
|
384
|
-
return index;
|
|
385
|
-
}
|
|
386
|
-
function decodeGeneratedRanges(input) {
|
|
387
|
-
const { length } = input;
|
|
388
|
-
const reader = new StringReader(input);
|
|
389
|
-
const ranges = [];
|
|
390
|
-
const stack = [];
|
|
391
|
-
let genLine = 0;
|
|
392
|
-
let definitionSourcesIndex = 0;
|
|
393
|
-
let definitionScopeIndex = 0;
|
|
394
|
-
let callsiteSourcesIndex = 0;
|
|
395
|
-
let callsiteLine = 0;
|
|
396
|
-
let callsiteColumn = 0;
|
|
397
|
-
let bindingLine = 0;
|
|
398
|
-
let bindingColumn = 0;
|
|
399
|
-
do {
|
|
400
|
-
const semi = reader.indexOf(';');
|
|
401
|
-
let genColumn = 0;
|
|
402
|
-
for (; reader.pos < semi; reader.pos++) {
|
|
403
|
-
genColumn = decodeInteger(reader, genColumn);
|
|
404
|
-
if (!hasMoreVlq(reader, semi)) {
|
|
405
|
-
const last = stack.pop();
|
|
406
|
-
last[2] = genLine;
|
|
407
|
-
last[3] = genColumn;
|
|
408
|
-
continue;
|
|
409
|
-
}
|
|
410
|
-
const fields = decodeInteger(reader, 0);
|
|
411
|
-
const hasDefinition = fields & 0b0001;
|
|
412
|
-
const hasCallsite = fields & 0b0010;
|
|
413
|
-
const hasScope = fields & 0b0100;
|
|
414
|
-
let callsite = null;
|
|
415
|
-
let bindings = EMPTY;
|
|
416
|
-
let range;
|
|
417
|
-
if (hasDefinition) {
|
|
418
|
-
const defSourcesIndex = decodeInteger(reader, definitionSourcesIndex);
|
|
419
|
-
definitionScopeIndex = decodeInteger(reader, definitionSourcesIndex === defSourcesIndex ? definitionScopeIndex : 0);
|
|
420
|
-
definitionSourcesIndex = defSourcesIndex;
|
|
421
|
-
range = [genLine, genColumn, 0, 0, defSourcesIndex, definitionScopeIndex];
|
|
422
|
-
}
|
|
423
|
-
else {
|
|
424
|
-
range = [genLine, genColumn, 0, 0];
|
|
425
|
-
}
|
|
426
|
-
range.isScope = !!hasScope;
|
|
427
|
-
if (hasCallsite) {
|
|
428
|
-
const prevCsi = callsiteSourcesIndex;
|
|
429
|
-
const prevLine = callsiteLine;
|
|
430
|
-
callsiteSourcesIndex = decodeInteger(reader, callsiteSourcesIndex);
|
|
431
|
-
const sameSource = prevCsi === callsiteSourcesIndex;
|
|
432
|
-
callsiteLine = decodeInteger(reader, sameSource ? callsiteLine : 0);
|
|
433
|
-
callsiteColumn = decodeInteger(reader, sameSource && prevLine === callsiteLine ? callsiteColumn : 0);
|
|
434
|
-
callsite = [callsiteSourcesIndex, callsiteLine, callsiteColumn];
|
|
435
|
-
}
|
|
436
|
-
range.callsite = callsite;
|
|
437
|
-
if (hasMoreVlq(reader, semi)) {
|
|
438
|
-
bindings = [];
|
|
439
|
-
do {
|
|
440
|
-
bindingLine = genLine;
|
|
441
|
-
bindingColumn = genColumn;
|
|
442
|
-
const expressionsCount = decodeInteger(reader, 0);
|
|
443
|
-
let expressionRanges;
|
|
444
|
-
if (expressionsCount < -1) {
|
|
445
|
-
expressionRanges = [[decodeInteger(reader, 0)]];
|
|
446
|
-
for (let i = -1; i > expressionsCount; i--) {
|
|
447
|
-
const prevBl = bindingLine;
|
|
448
|
-
bindingLine = decodeInteger(reader, bindingLine);
|
|
449
|
-
bindingColumn = decodeInteger(reader, bindingLine === prevBl ? bindingColumn : 0);
|
|
450
|
-
const expression = decodeInteger(reader, 0);
|
|
451
|
-
expressionRanges.push([expression, bindingLine, bindingColumn]);
|
|
452
|
-
}
|
|
453
|
-
}
|
|
454
|
-
else {
|
|
455
|
-
expressionRanges = [[expressionsCount]];
|
|
456
|
-
}
|
|
457
|
-
bindings.push(expressionRanges);
|
|
458
|
-
} while (hasMoreVlq(reader, semi));
|
|
459
|
-
}
|
|
460
|
-
range.bindings = bindings;
|
|
461
|
-
ranges.push(range);
|
|
462
|
-
stack.push(range);
|
|
463
|
-
}
|
|
464
|
-
genLine++;
|
|
465
|
-
reader.pos = semi + 1;
|
|
466
|
-
} while (reader.pos < length);
|
|
467
|
-
return ranges;
|
|
468
|
-
}
|
|
469
|
-
function encodeGeneratedRanges(ranges) {
|
|
470
|
-
if (ranges.length === 0)
|
|
471
|
-
return '';
|
|
472
|
-
const writer = new StringWriter();
|
|
473
|
-
for (let i = 0; i < ranges.length;) {
|
|
474
|
-
i = _encodeGeneratedRanges(ranges, i, writer, [0, 0, 0, 0, 0, 0, 0]);
|
|
475
|
-
}
|
|
476
|
-
return writer.flush();
|
|
477
|
-
}
|
|
478
|
-
function _encodeGeneratedRanges(ranges, index, writer, state) {
|
|
479
|
-
const range = ranges[index];
|
|
480
|
-
const { 0: startLine, 1: startColumn, 2: endLine, 3: endColumn, isScope, callsite, bindings, } = range;
|
|
481
|
-
if (state[0] < startLine) {
|
|
482
|
-
catchupLine(writer, state[0], startLine);
|
|
483
|
-
state[0] = startLine;
|
|
484
|
-
state[1] = 0;
|
|
485
|
-
}
|
|
486
|
-
else if (index > 0) {
|
|
487
|
-
writer.write(comma);
|
|
488
|
-
}
|
|
489
|
-
state[1] = encodeInteger(writer, range[1], state[1]);
|
|
490
|
-
const fields = (range.length === 6 ? 0b0001 : 0) | (callsite ? 0b0010 : 0) | (isScope ? 0b0100 : 0);
|
|
491
|
-
encodeInteger(writer, fields, 0);
|
|
492
|
-
if (range.length === 6) {
|
|
493
|
-
const { 4: sourcesIndex, 5: scopesIndex } = range;
|
|
494
|
-
if (sourcesIndex !== state[2]) {
|
|
495
|
-
state[3] = 0;
|
|
496
|
-
}
|
|
497
|
-
state[2] = encodeInteger(writer, sourcesIndex, state[2]);
|
|
498
|
-
state[3] = encodeInteger(writer, scopesIndex, state[3]);
|
|
499
|
-
}
|
|
500
|
-
if (callsite) {
|
|
501
|
-
const { 0: sourcesIndex, 1: callLine, 2: callColumn } = range.callsite;
|
|
502
|
-
if (sourcesIndex !== state[4]) {
|
|
503
|
-
state[5] = 0;
|
|
504
|
-
state[6] = 0;
|
|
505
|
-
}
|
|
506
|
-
else if (callLine !== state[5]) {
|
|
507
|
-
state[6] = 0;
|
|
508
|
-
}
|
|
509
|
-
state[4] = encodeInteger(writer, sourcesIndex, state[4]);
|
|
510
|
-
state[5] = encodeInteger(writer, callLine, state[5]);
|
|
511
|
-
state[6] = encodeInteger(writer, callColumn, state[6]);
|
|
512
|
-
}
|
|
513
|
-
if (bindings) {
|
|
514
|
-
for (const binding of bindings) {
|
|
515
|
-
if (binding.length > 1)
|
|
516
|
-
encodeInteger(writer, -binding.length, 0);
|
|
517
|
-
const expression = binding[0][0];
|
|
518
|
-
encodeInteger(writer, expression, 0);
|
|
519
|
-
let bindingStartLine = startLine;
|
|
520
|
-
let bindingStartColumn = startColumn;
|
|
521
|
-
for (let i = 1; i < binding.length; i++) {
|
|
522
|
-
const expRange = binding[i];
|
|
523
|
-
bindingStartLine = encodeInteger(writer, expRange[1], bindingStartLine);
|
|
524
|
-
bindingStartColumn = encodeInteger(writer, expRange[2], bindingStartColumn);
|
|
525
|
-
encodeInteger(writer, expRange[0], 0);
|
|
526
|
-
}
|
|
527
|
-
}
|
|
528
|
-
}
|
|
529
|
-
for (index++; index < ranges.length;) {
|
|
530
|
-
const next = ranges[index];
|
|
531
|
-
const { 0: l, 1: c } = next;
|
|
532
|
-
if (l > endLine || (l === endLine && c >= endColumn)) {
|
|
533
|
-
break;
|
|
534
|
-
}
|
|
535
|
-
index = _encodeGeneratedRanges(ranges, index, writer, state);
|
|
536
|
-
}
|
|
537
|
-
if (state[0] < endLine) {
|
|
538
|
-
catchupLine(writer, state[0], endLine);
|
|
539
|
-
state[0] = endLine;
|
|
540
|
-
state[1] = 0;
|
|
541
|
-
}
|
|
542
|
-
else {
|
|
543
|
-
writer.write(comma);
|
|
544
|
-
}
|
|
545
|
-
state[1] = encodeInteger(writer, endColumn, state[1]);
|
|
546
|
-
return index;
|
|
547
|
-
}
|
|
548
|
-
function catchupLine(writer, lastLine, line) {
|
|
549
|
-
do {
|
|
550
|
-
writer.write(semicolon);
|
|
551
|
-
} while (++lastLine < line);
|
|
552
|
-
}
|
|
553
|
-
|
|
554
|
-
function decode(mappings) {
|
|
555
|
-
const { length } = mappings;
|
|
556
|
-
const reader = new StringReader(mappings);
|
|
557
|
-
const decoded = [];
|
|
558
|
-
let genColumn = 0;
|
|
559
|
-
let sourcesIndex = 0;
|
|
560
|
-
let sourceLine = 0;
|
|
561
|
-
let sourceColumn = 0;
|
|
562
|
-
let namesIndex = 0;
|
|
563
|
-
do {
|
|
564
|
-
const semi = reader.indexOf(';');
|
|
565
|
-
const line = [];
|
|
566
|
-
let sorted = true;
|
|
567
|
-
let lastCol = 0;
|
|
568
|
-
genColumn = 0;
|
|
569
|
-
while (reader.pos < semi) {
|
|
570
|
-
let seg;
|
|
571
|
-
genColumn = decodeInteger(reader, genColumn);
|
|
572
|
-
if (genColumn < lastCol)
|
|
573
|
-
sorted = false;
|
|
574
|
-
lastCol = genColumn;
|
|
575
|
-
if (hasMoreVlq(reader, semi)) {
|
|
576
|
-
sourcesIndex = decodeInteger(reader, sourcesIndex);
|
|
577
|
-
sourceLine = decodeInteger(reader, sourceLine);
|
|
578
|
-
sourceColumn = decodeInteger(reader, sourceColumn);
|
|
579
|
-
if (hasMoreVlq(reader, semi)) {
|
|
580
|
-
namesIndex = decodeInteger(reader, namesIndex);
|
|
581
|
-
seg = [genColumn, sourcesIndex, sourceLine, sourceColumn, namesIndex];
|
|
582
|
-
}
|
|
583
|
-
else {
|
|
584
|
-
seg = [genColumn, sourcesIndex, sourceLine, sourceColumn];
|
|
585
|
-
}
|
|
586
|
-
}
|
|
587
|
-
else {
|
|
588
|
-
seg = [genColumn];
|
|
589
|
-
}
|
|
590
|
-
line.push(seg);
|
|
591
|
-
reader.pos++;
|
|
592
|
-
}
|
|
593
|
-
if (!sorted)
|
|
594
|
-
sort(line);
|
|
595
|
-
decoded.push(line);
|
|
596
|
-
reader.pos = semi + 1;
|
|
597
|
-
} while (reader.pos <= length);
|
|
598
|
-
return decoded;
|
|
599
|
-
}
|
|
600
|
-
function sort(line) {
|
|
601
|
-
line.sort(sortComparator);
|
|
602
|
-
}
|
|
603
|
-
function sortComparator(a, b) {
|
|
604
|
-
return a[0] - b[0];
|
|
605
|
-
}
|
|
606
|
-
function encode(decoded) {
|
|
607
|
-
const writer = new StringWriter();
|
|
608
|
-
let sourcesIndex = 0;
|
|
609
|
-
let sourceLine = 0;
|
|
610
|
-
let sourceColumn = 0;
|
|
611
|
-
let namesIndex = 0;
|
|
612
|
-
for (let i = 0; i < decoded.length; i++) {
|
|
613
|
-
const line = decoded[i];
|
|
614
|
-
if (i > 0)
|
|
615
|
-
writer.write(semicolon);
|
|
616
|
-
if (line.length === 0)
|
|
617
|
-
continue;
|
|
618
|
-
let genColumn = 0;
|
|
619
|
-
for (let j = 0; j < line.length; j++) {
|
|
620
|
-
const segment = line[j];
|
|
621
|
-
if (j > 0)
|
|
622
|
-
writer.write(comma);
|
|
623
|
-
genColumn = encodeInteger(writer, segment[0], genColumn);
|
|
624
|
-
if (segment.length === 1)
|
|
625
|
-
continue;
|
|
626
|
-
sourcesIndex = encodeInteger(writer, segment[1], sourcesIndex);
|
|
627
|
-
sourceLine = encodeInteger(writer, segment[2], sourceLine);
|
|
628
|
-
sourceColumn = encodeInteger(writer, segment[3], sourceColumn);
|
|
629
|
-
if (segment.length === 4)
|
|
630
|
-
continue;
|
|
631
|
-
namesIndex = encodeInteger(writer, segment[4], namesIndex);
|
|
632
|
-
}
|
|
633
|
-
}
|
|
634
|
-
return writer.flush();
|
|
635
|
-
}
|
|
636
|
-
|
|
637
|
-
exports.decode = decode;
|
|
638
|
-
exports.decodeGeneratedRanges = decodeGeneratedRanges;
|
|
639
|
-
exports.decodeOriginalScopes = decodeOriginalScopes;
|
|
640
|
-
exports.encode = encode;
|
|
641
|
-
exports.encodeGeneratedRanges = encodeGeneratedRanges;
|
|
642
|
-
exports.encodeOriginalScopes = encodeOriginalScopes;
|
|
643
|
-
|
|
644
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
645
|
-
|
|
646
|
-
}));
|
|
647
|
-
|
|
648
|
-
} (sourcemapCodec_umd$1, sourcemapCodec_umd$1.exports));
|
|
649
|
-
return sourcemapCodec_umd$1.exports;
|
|
202
|
+
// src/vlq.ts
|
|
203
|
+
var comma = ",".charCodeAt(0);
|
|
204
|
+
var semicolon = ";".charCodeAt(0);
|
|
205
|
+
var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
206
|
+
var intToChar = new Uint8Array(64);
|
|
207
|
+
var charToInt = new Uint8Array(128);
|
|
208
|
+
for (let i = 0; i < chars.length; i++) {
|
|
209
|
+
const c = chars.charCodeAt(i);
|
|
210
|
+
intToChar[i] = c;
|
|
211
|
+
charToInt[c] = i;
|
|
212
|
+
}
|
|
213
|
+
function encodeInteger(builder, num, relative) {
|
|
214
|
+
let delta = num - relative;
|
|
215
|
+
delta = delta < 0 ? -delta << 1 | 1 : delta << 1;
|
|
216
|
+
do {
|
|
217
|
+
let clamped = delta & 31;
|
|
218
|
+
delta >>>= 5;
|
|
219
|
+
if (delta > 0) clamped |= 32;
|
|
220
|
+
builder.write(intToChar[clamped]);
|
|
221
|
+
} while (delta > 0);
|
|
222
|
+
return num;
|
|
650
223
|
}
|
|
651
224
|
|
|
652
|
-
|
|
225
|
+
// src/strings.ts
|
|
226
|
+
var bufLength = 1024 * 16;
|
|
227
|
+
var td = typeof TextDecoder !== "undefined" ? /* @__PURE__ */ new TextDecoder() : typeof Buffer !== "undefined" ? {
|
|
228
|
+
decode(buf) {
|
|
229
|
+
const out = Buffer.from(buf.buffer, buf.byteOffset, buf.byteLength);
|
|
230
|
+
return out.toString();
|
|
231
|
+
}
|
|
232
|
+
} : {
|
|
233
|
+
decode(buf) {
|
|
234
|
+
let out = "";
|
|
235
|
+
for (let i = 0; i < buf.length; i++) {
|
|
236
|
+
out += String.fromCharCode(buf[i]);
|
|
237
|
+
}
|
|
238
|
+
return out;
|
|
239
|
+
}
|
|
240
|
+
};
|
|
241
|
+
var StringWriter = class {
|
|
242
|
+
constructor() {
|
|
243
|
+
this.pos = 0;
|
|
244
|
+
this.out = "";
|
|
245
|
+
this.buffer = new Uint8Array(bufLength);
|
|
246
|
+
}
|
|
247
|
+
write(v) {
|
|
248
|
+
const { buffer } = this;
|
|
249
|
+
buffer[this.pos++] = v;
|
|
250
|
+
if (this.pos === bufLength) {
|
|
251
|
+
this.out += td.decode(buffer);
|
|
252
|
+
this.pos = 0;
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
flush() {
|
|
256
|
+
const { buffer, out, pos } = this;
|
|
257
|
+
return pos > 0 ? out + td.decode(buffer.subarray(0, pos)) : out;
|
|
258
|
+
}
|
|
259
|
+
};
|
|
260
|
+
function encode(decoded) {
|
|
261
|
+
const writer = new StringWriter();
|
|
262
|
+
let sourcesIndex = 0;
|
|
263
|
+
let sourceLine = 0;
|
|
264
|
+
let sourceColumn = 0;
|
|
265
|
+
let namesIndex = 0;
|
|
266
|
+
for (let i = 0; i < decoded.length; i++) {
|
|
267
|
+
const line = decoded[i];
|
|
268
|
+
if (i > 0) writer.write(semicolon);
|
|
269
|
+
if (line.length === 0) continue;
|
|
270
|
+
let genColumn = 0;
|
|
271
|
+
for (let j = 0; j < line.length; j++) {
|
|
272
|
+
const segment = line[j];
|
|
273
|
+
if (j > 0) writer.write(comma);
|
|
274
|
+
genColumn = encodeInteger(writer, segment[0], genColumn);
|
|
275
|
+
if (segment.length === 1) continue;
|
|
276
|
+
sourcesIndex = encodeInteger(writer, segment[1], sourcesIndex);
|
|
277
|
+
sourceLine = encodeInteger(writer, segment[2], sourceLine);
|
|
278
|
+
sourceColumn = encodeInteger(writer, segment[3], sourceColumn);
|
|
279
|
+
if (segment.length === 4) continue;
|
|
280
|
+
namesIndex = encodeInteger(writer, segment[4], namesIndex);
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
return writer.flush();
|
|
284
|
+
}
|
|
653
285
|
|
|
654
286
|
class BitSet {
|
|
655
287
|
constructor(arg) {
|
|
@@ -865,7 +497,7 @@ class SourceMap {
|
|
|
865
497
|
this.sources = properties.sources;
|
|
866
498
|
this.sourcesContent = properties.sourcesContent;
|
|
867
499
|
this.names = properties.names;
|
|
868
|
-
this.mappings =
|
|
500
|
+
this.mappings = encode(properties.mappings);
|
|
869
501
|
if (typeof properties.x_google_ignoreList !== 'undefined') {
|
|
870
502
|
this.x_google_ignoreList = properties.x_google_ignoreList;
|
|
871
503
|
}
|
|
@@ -2808,6 +2440,49 @@ pp$8.isAsyncFunction = function() {
|
|
|
2808
2440
|
!(isIdentifierChar(after = this.input.charCodeAt(next + 8)) || after > 0xd7ff && after < 0xdc00))
|
|
2809
2441
|
};
|
|
2810
2442
|
|
|
2443
|
+
pp$8.isUsingKeyword = function(isAwaitUsing, isFor) {
|
|
2444
|
+
if (this.options.ecmaVersion < 17 || !this.isContextual(isAwaitUsing ? "await" : "using"))
|
|
2445
|
+
{ return false }
|
|
2446
|
+
|
|
2447
|
+
skipWhiteSpace.lastIndex = this.pos;
|
|
2448
|
+
var skip = skipWhiteSpace.exec(this.input);
|
|
2449
|
+
var next = this.pos + skip[0].length;
|
|
2450
|
+
|
|
2451
|
+
if (lineBreak.test(this.input.slice(this.pos, next))) { return false }
|
|
2452
|
+
|
|
2453
|
+
if (isAwaitUsing) {
|
|
2454
|
+
var awaitEndPos = next + 5 /* await */, after;
|
|
2455
|
+
if (this.input.slice(next, awaitEndPos) !== "using" ||
|
|
2456
|
+
awaitEndPos === this.input.length ||
|
|
2457
|
+
isIdentifierChar(after = this.input.charCodeAt(awaitEndPos)) ||
|
|
2458
|
+
(after > 0xd7ff && after < 0xdc00)
|
|
2459
|
+
) { return false }
|
|
2460
|
+
|
|
2461
|
+
skipWhiteSpace.lastIndex = awaitEndPos;
|
|
2462
|
+
var skipAfterUsing = skipWhiteSpace.exec(this.input);
|
|
2463
|
+
if (skipAfterUsing && lineBreak.test(this.input.slice(awaitEndPos, awaitEndPos + skipAfterUsing[0].length))) { return false }
|
|
2464
|
+
}
|
|
2465
|
+
|
|
2466
|
+
if (isFor) {
|
|
2467
|
+
var ofEndPos = next + 2 /* of */, after$1;
|
|
2468
|
+
if (this.input.slice(next, ofEndPos) === "of") {
|
|
2469
|
+
if (ofEndPos === this.input.length ||
|
|
2470
|
+
(!isIdentifierChar(after$1 = this.input.charCodeAt(ofEndPos)) && !(after$1 > 0xd7ff && after$1 < 0xdc00))) { return false }
|
|
2471
|
+
}
|
|
2472
|
+
}
|
|
2473
|
+
|
|
2474
|
+
var ch = this.input.charCodeAt(next);
|
|
2475
|
+
return isIdentifierStart(ch, true) || ch === 92 // '\'
|
|
2476
|
+
};
|
|
2477
|
+
|
|
2478
|
+
pp$8.isAwaitUsing = function(isFor) {
|
|
2479
|
+
return this.isUsingKeyword(true, isFor)
|
|
2480
|
+
};
|
|
2481
|
+
|
|
2482
|
+
pp$8.isUsing = function(isFor) {
|
|
2483
|
+
return this.isUsingKeyword(false, isFor)
|
|
2484
|
+
};
|
|
2485
|
+
|
|
2811
2486
|
// Parse a single statement.
|
|
2812
2487
|
//
|
|
2813
2488
|
// If expecting a statement and finding a slash operator, parse a
|
|
@@ -2884,6 +2559,23 @@ pp$8.parseStatement = function(context, topLevel, exports) {
|
|
|
2884
2559
|
return this.parseFunctionStatement(node, true, !context)
|
|
2885
2560
|
}
|
|
2886
2561
|
|
|
2562
|
+
var usingKind = this.isAwaitUsing(false) ? "await using" : this.isUsing(false) ? "using" : null;
|
|
2563
|
+
if (usingKind) {
|
|
2564
|
+
if (topLevel && this.options.sourceType === "script") {
|
|
2565
|
+
this.raise(this.start, "Using declaration cannot appear in the top level when source type is `script`");
|
|
2566
|
+
}
|
|
2567
|
+
if (usingKind === "await using") {
|
|
2568
|
+
if (!this.canAwait) {
|
|
2569
|
+
this.raise(this.start, "Await using cannot appear outside of async function");
|
|
2570
|
+
}
|
|
2571
|
+
this.next();
|
|
2572
|
+
}
|
|
2573
|
+
this.next();
|
|
2574
|
+
this.parseVar(node, false, usingKind);
|
|
2575
|
+
this.semicolon();
|
|
2576
|
+
return this.finishNode(node, "VariableDeclaration")
|
|
2577
|
+
}
|
|
2578
|
+
|
|
2887
2579
|
var maybeName = this.value, expr = this.parseExpression();
|
|
2888
2580
|
if (starttype === types$1.name && expr.type === "Identifier" && this.eat(types$1.colon))
|
|
2889
2581
|
{ return this.parseLabeledStatement(node, maybeName, expr, context) }
|
|
@@ -2959,18 +2651,19 @@ pp$8.parseForStatement = function(node) {
|
|
|
2959
2651
|
this.next();
|
|
2960
2652
|
this.parseVar(init$1, true, kind);
|
|
2961
2653
|
this.finishNode(init$1, "VariableDeclaration");
|
|
2962
|
-
|
|
2963
|
-
if (this.options.ecmaVersion >= 9) {
|
|
2964
|
-
if (this.type === types$1._in) {
|
|
2965
|
-
if (awaitAt > -1) { this.unexpected(awaitAt); }
|
|
2966
|
-
} else { node.await = awaitAt > -1; }
|
|
2967
|
-
}
|
|
2968
|
-
return this.parseForIn(node, init$1)
|
|
2969
|
-
}
|
|
2970
|
-
if (awaitAt > -1) { this.unexpected(awaitAt); }
|
|
2971
|
-
return this.parseFor(node, init$1)
|
|
2654
|
+
return this.parseForAfterInit(node, init$1, awaitAt)
|
|
2972
2655
|
}
|
|
2973
2656
|
var startsWithLet = this.isContextual("let"), isForOf = false;
|
|
2657
|
+
|
|
2658
|
+
var usingKind = this.isUsing(true) ? "using" : this.isAwaitUsing(true) ? "await using" : null;
|
|
2659
|
+
if (usingKind) {
|
|
2660
|
+
var init$2 = this.startNode();
|
|
2661
|
+
this.next();
|
|
2662
|
+
if (usingKind === "await using") { this.next(); }
|
|
2663
|
+
this.parseVar(init$2, true, usingKind);
|
|
2664
|
+
this.finishNode(init$2, "VariableDeclaration");
|
|
2665
|
+
return this.parseForAfterInit(node, init$2, awaitAt)
|
|
2666
|
+
}
|
|
2974
2667
|
var containsEsc = this.containsEsc;
|
|
2975
2668
|
var refDestructuringErrors = new DestructuringErrors;
|
|
2976
2669
|
var initPos = this.start;
|
|
@@ -2996,6 +2689,20 @@ pp$8.parseForStatement = function(node) {
|
|
|
2996
2689
|
return this.parseFor(node, init)
|
|
2997
2690
|
};
|
|
2998
2691
|
|
|
2692
|
+
// Helper method to parse for loop after variable initialization
|
|
2693
|
+
pp$8.parseForAfterInit = function(node, init, awaitAt) {
|
|
2694
|
+
if ((this.type === types$1._in || (this.options.ecmaVersion >= 6 && this.isContextual("of"))) && init.declarations.length === 1) {
|
|
2695
|
+
if (this.options.ecmaVersion >= 9) {
|
|
2696
|
+
if (this.type === types$1._in) {
|
|
2697
|
+
if (awaitAt > -1) { this.unexpected(awaitAt); }
|
|
2698
|
+
} else { node.await = awaitAt > -1; }
|
|
2699
|
+
}
|
|
2700
|
+
return this.parseForIn(node, init)
|
|
2701
|
+
}
|
|
2702
|
+
if (awaitAt > -1) { this.unexpected(awaitAt); }
|
|
2703
|
+
return this.parseFor(node, init)
|
|
2704
|
+
};
|
|
2705
|
+
|
|
2999
2706
|
pp$8.parseFunctionStatement = function(node, isAsync, declarationPosition) {
|
|
3000
2707
|
this.next();
|
|
3001
2708
|
return this.parseFunction(node, FUNC_STATEMENT | (declarationPosition ? 0 : FUNC_HANGING_STATEMENT), false, isAsync)
|
|
@@ -3252,6 +2959,8 @@ pp$8.parseVar = function(node, isFor, kind, allowMissingInitializer) {
|
|
|
3252
2959
|
decl.init = this.parseMaybeAssign(isFor);
|
|
3253
2960
|
} else if (!allowMissingInitializer && kind === "const" && !(this.type === types$1._in || (this.options.ecmaVersion >= 6 && this.isContextual("of")))) {
|
|
3254
2961
|
this.unexpected();
|
|
2962
|
+
} else if (!allowMissingInitializer && (kind === "using" || kind === "await using") && this.options.ecmaVersion >= 17 && this.type !== types$1._in && !this.isContextual("of")) {
|
|
2963
|
+
this.raise(this.lastTokEnd, ("Missing initializer in " + kind + " declaration"));
|
|
3255
2964
|
} else if (!allowMissingInitializer && decl.id.type !== "Identifier" && !(isFor && (this.type === types$1._in || this.isContextual("of")))) {
|
|
3256
2965
|
this.raise(this.lastTokEnd, "Complex binding patterns require an initialization value");
|
|
3257
2966
|
} else {
|
|
@@ -3264,7 +2973,10 @@ pp$8.parseVar = function(node, isFor, kind, allowMissingInitializer) {
|
|
|
3264
2973
|
};
|
|
3265
2974
|
|
|
3266
2975
|
pp$8.parseVarId = function(decl, kind) {
|
|
3267
|
-
decl.id =
|
|
2976
|
+
decl.id = kind === "using" || kind === "await using"
|
|
2977
|
+
? this.parseIdent()
|
|
2978
|
+
: this.parseBindingAtom();
|
|
2979
|
+
|
|
3268
2980
|
this.checkLValPattern(decl.id, kind === "var" ? BIND_VAR : BIND_LEXICAL, false);
|
|
3269
2981
|
};
|
|
3270
2982
|
|
|
@@ -4995,7 +4707,8 @@ pp$5.parseLiteral = function(value) {
|
|
|
4995
4707
|
var node = this.startNode();
|
|
4996
4708
|
node.value = value;
|
|
4997
4709
|
node.raw = this.input.slice(this.start, this.end);
|
|
4998
|
-
if (node.raw.charCodeAt(node.raw.length - 1) === 110)
|
|
4710
|
+
if (node.raw.charCodeAt(node.raw.length - 1) === 110)
|
|
4711
|
+
{ node.bigint = node.value != null ? node.value.toString() : node.raw.slice(0, -1).replace(/_/g, ""); }
|
|
4999
4712
|
this.next();
|
|
5000
4713
|
return this.finishNode(node, "Literal")
|
|
5001
4714
|
};
|
|
@@ -8025,11 +7738,9 @@ pp.readWord = function() {
|
|
|
8025
7738
|
// Please use the [github bug tracker][ghbt] to report issues.
|
|
8026
7739
|
//
|
|
8027
7740
|
// [ghbt]: https://github.com/acornjs/acorn/issues
|
|
8028
|
-
//
|
|
8029
|
-
// [walk]: util/walk.js
|
|
8030
7741
|
|
|
8031
7742
|
|
|
8032
|
-
var version = "8.
|
|
7743
|
+
var version = "8.15.0";
|
|
8033
7744
|
|
|
8034
7745
|
Parser.acorn = {
|
|
8035
7746
|
Parser: Parser,
|
|
@@ -8639,7 +8350,7 @@ class Room {
|
|
|
8639
8350
|
this.storageData.delete(key);
|
|
8640
8351
|
},
|
|
8641
8352
|
list: async () => {
|
|
8642
|
-
return Array.from(this.storageData.
|
|
8353
|
+
return Array.from(this.storageData.entries());
|
|
8643
8354
|
}
|
|
8644
8355
|
};
|
|
8645
8356
|
}
|
|
@@ -8663,6 +8374,113 @@ function serverPlugin(serverModule) {
|
|
|
8663
8374
|
let wsServer = null;
|
|
8664
8375
|
let rooms = /* @__PURE__ */ new Map();
|
|
8665
8376
|
let servers = /* @__PURE__ */ new Map();
|
|
8377
|
+
async function ensureRoomAndServer(roomId) {
|
|
8378
|
+
let room = rooms.get(roomId);
|
|
8379
|
+
if (!room) {
|
|
8380
|
+
room = new Room(roomId);
|
|
8381
|
+
rooms.set(roomId, room);
|
|
8382
|
+
console.log(`Created new room: ${roomId}`);
|
|
8383
|
+
}
|
|
8384
|
+
let rpgServer = servers.get(roomId);
|
|
8385
|
+
if (!rpgServer) {
|
|
8386
|
+
rpgServer = new serverModule(room);
|
|
8387
|
+
servers.set(roomId, rpgServer);
|
|
8388
|
+
console.log(`Created new server instance for room: ${roomId}`);
|
|
8389
|
+
if (typeof rpgServer.onStart === "function") {
|
|
8390
|
+
try {
|
|
8391
|
+
await rpgServer.onStart();
|
|
8392
|
+
console.log(`Server started for room: ${roomId}`);
|
|
8393
|
+
} catch (error) {
|
|
8394
|
+
console.error(`Error starting server for room ${roomId}:`, error);
|
|
8395
|
+
}
|
|
8396
|
+
}
|
|
8397
|
+
try {
|
|
8398
|
+
const mapId = roomId.startsWith("map-") ? roomId.slice(4) : roomId;
|
|
8399
|
+
const defaultMapPayload = {
|
|
8400
|
+
id: mapId,
|
|
8401
|
+
width: 1e3,
|
|
8402
|
+
height: 1e3,
|
|
8403
|
+
events: []
|
|
8404
|
+
};
|
|
8405
|
+
const req = {
|
|
8406
|
+
url: `http://localhost/parties/main/${roomId}/map/update`,
|
|
8407
|
+
method: "POST",
|
|
8408
|
+
headers: new Headers({}),
|
|
8409
|
+
json: async () => defaultMapPayload,
|
|
8410
|
+
text: async () => JSON.stringify(defaultMapPayload)
|
|
8411
|
+
};
|
|
8412
|
+
await rpgServer.onRequest(req);
|
|
8413
|
+
console.log(`Initialized map for room ${roomId} via POST /map/update`);
|
|
8414
|
+
} catch (error) {
|
|
8415
|
+
console.warn(`Failed initializing map for room ${roomId}:`, error);
|
|
8416
|
+
}
|
|
8417
|
+
}
|
|
8418
|
+
room.context.parties = buildPartiesContext();
|
|
8419
|
+
return { room, rpgServer };
|
|
8420
|
+
}
|
|
8421
|
+
function buildPartiesContext() {
|
|
8422
|
+
return {
|
|
8423
|
+
main: {
|
|
8424
|
+
get: async (targetRoomId) => {
|
|
8425
|
+
const { rpgServer } = await ensureRoomAndServer(targetRoomId);
|
|
8426
|
+
return {
|
|
8427
|
+
fetch: async (path, init) => {
|
|
8428
|
+
try {
|
|
8429
|
+
const url = `http://localhost/parties/main/${targetRoomId}${path}`;
|
|
8430
|
+
const method = (init?.method || "GET").toUpperCase();
|
|
8431
|
+
const headers = new Headers(init?.headers || {});
|
|
8432
|
+
const bodyRaw = init?.body;
|
|
8433
|
+
const req = {
|
|
8434
|
+
url,
|
|
8435
|
+
method,
|
|
8436
|
+
headers,
|
|
8437
|
+
json: async () => {
|
|
8438
|
+
if (!bodyRaw) return void 0;
|
|
8439
|
+
return typeof bodyRaw === "string" ? JSON.parse(bodyRaw) : bodyRaw;
|
|
8440
|
+
},
|
|
8441
|
+
text: async () => {
|
|
8442
|
+
if (typeof bodyRaw === "string") return bodyRaw;
|
|
8443
|
+
if (typeof bodyRaw === "undefined") return "";
|
|
8444
|
+
return JSON.stringify(bodyRaw);
|
|
8445
|
+
}
|
|
8446
|
+
};
|
|
8447
|
+
const result = await rpgServer.onRequest(req);
|
|
8448
|
+
const ok = !!result && (result.ok === true || typeof result !== "undefined");
|
|
8449
|
+
const response = {
|
|
8450
|
+
ok,
|
|
8451
|
+
status: ok ? 200 : 404,
|
|
8452
|
+
async json() {
|
|
8453
|
+
if (result && typeof result.json === "function") return result.json();
|
|
8454
|
+
return result ?? {};
|
|
8455
|
+
},
|
|
8456
|
+
async text() {
|
|
8457
|
+
if (typeof result === "string") return result;
|
|
8458
|
+
try {
|
|
8459
|
+
return JSON.stringify(result ?? {});
|
|
8460
|
+
} catch {
|
|
8461
|
+
return "";
|
|
8462
|
+
}
|
|
8463
|
+
}
|
|
8464
|
+
};
|
|
8465
|
+
return response;
|
|
8466
|
+
} catch (error) {
|
|
8467
|
+
return {
|
|
8468
|
+
ok: false,
|
|
8469
|
+
status: 500,
|
|
8470
|
+
async json() {
|
|
8471
|
+
return { error: error?.message || "Internal error" };
|
|
8472
|
+
},
|
|
8473
|
+
async text() {
|
|
8474
|
+
return error?.message || "Internal error";
|
|
8475
|
+
}
|
|
8476
|
+
};
|
|
8477
|
+
}
|
|
8478
|
+
}
|
|
8479
|
+
};
|
|
8480
|
+
}
|
|
8481
|
+
}
|
|
8482
|
+
};
|
|
8483
|
+
}
|
|
8666
8484
|
return {
|
|
8667
8485
|
name: "server-plugin",
|
|
8668
8486
|
async configureServer(server) {
|
|
@@ -8724,29 +8542,13 @@ function serverPlugin(serverModule) {
|
|
|
8724
8542
|
`Room: ${roomName}, Query params:`,
|
|
8725
8543
|
queryParams
|
|
8726
8544
|
);
|
|
8727
|
-
|
|
8728
|
-
|
|
8729
|
-
|
|
8730
|
-
|
|
8731
|
-
console.log(`Created new room: ${roomName}`);
|
|
8732
|
-
}
|
|
8733
|
-
let rpgServer = servers.get(roomName);
|
|
8734
|
-
if (!rpgServer) {
|
|
8735
|
-
rpgServer = new serverModule(room);
|
|
8736
|
-
servers.set(roomName, rpgServer);
|
|
8737
|
-
console.log(`Created new server instance for room: ${roomName}`);
|
|
8738
|
-
if (typeof rpgServer.onStart === "function") {
|
|
8739
|
-
try {
|
|
8740
|
-
await rpgServer.onStart();
|
|
8741
|
-
console.log(`Server started for room: ${roomName}`);
|
|
8742
|
-
} catch (error) {
|
|
8743
|
-
console.error(`Error starting server for room ${roomName}:`, error);
|
|
8744
|
-
}
|
|
8745
|
-
}
|
|
8746
|
-
}
|
|
8545
|
+
const ensured = await ensureRoomAndServer(roomName);
|
|
8546
|
+
const room = ensured.room;
|
|
8547
|
+
const rpgServer = ensured.rpgServer;
|
|
8548
|
+
room.context.parties = buildPartiesContext();
|
|
8747
8549
|
const connection = new PartyConnection(
|
|
8748
8550
|
ws,
|
|
8749
|
-
|
|
8551
|
+
queryParams._pk,
|
|
8750
8552
|
request.url
|
|
8751
8553
|
);
|
|
8752
8554
|
room.addConnection(connection);
|
|
@@ -8803,7 +8605,7 @@ function serverPlugin(serverModule) {
|
|
|
8803
8605
|
keys: () => headers.keys(),
|
|
8804
8606
|
values: () => headers.values()
|
|
8805
8607
|
},
|
|
8806
|
-
url:
|
|
8608
|
+
url: url.toString(),
|
|
8807
8609
|
method: request.method
|
|
8808
8610
|
},
|
|
8809
8611
|
url
|