mirror of https://github.com/status-im/metro.git
Updates from Thu Sep 3rd.
This commit is contained in:
commit
bad0a5cb46
|
@ -126,7 +126,7 @@ describe('processRequest', () => {
|
|||
expect(Bundler.prototype.bundle).toBeCalledWith(
|
||||
'index.js',
|
||||
true,
|
||||
'index.map',
|
||||
'index.map?platform=ios',
|
||||
true,
|
||||
'ios',
|
||||
);
|
||||
|
@ -271,7 +271,7 @@ describe('processRequest', () => {
|
|||
expect(Bundler.prototype.bundle).toBeCalledWith(
|
||||
'path/to/foo.js',
|
||||
false,
|
||||
'/path/to/foo.map',
|
||||
'/path/to/foo.map?dev=false&runModule=false',
|
||||
false,
|
||||
undefined
|
||||
);
|
||||
|
|
|
@ -429,8 +429,11 @@ class Server {
|
|||
return true;
|
||||
}).join('.') + '.js';
|
||||
|
||||
const sourceMapUrlObj = _.clone(urlObj);
|
||||
sourceMapUrlObj.pathname = pathname.replace(/\.bundle$/, '.map');
|
||||
|
||||
return {
|
||||
sourceMapUrl: pathname.replace(/\.bundle$/, '.map'),
|
||||
sourceMapUrl: url.format(sourceMapUrlObj),
|
||||
entryFile: entryFile,
|
||||
dev: this._getBoolOptionFromQuery(urlObj.query, 'dev', true),
|
||||
minify: this._getBoolOptionFromQuery(urlObj.query, 'minify'),
|
||||
|
|
|
@ -15,7 +15,7 @@ const debug = require('debug')('ReactPackager:SocketServer');
|
|||
const fs = require('fs');
|
||||
const net = require('net');
|
||||
|
||||
const MAX_IDLE_TIME = 10 * 60 * 1000;
|
||||
const MAX_IDLE_TIME = 30 * 1000;
|
||||
|
||||
class SocketServer {
|
||||
constructor(sockPath, options) {
|
||||
|
@ -118,7 +118,7 @@ class SocketServer {
|
|||
this._deathTimer = setTimeout(() => {
|
||||
if (this._jobs <= 0) {
|
||||
debug('server dying', process.pid);
|
||||
process.exit(1);
|
||||
process.exit();
|
||||
}
|
||||
this._dieEventually();
|
||||
}, MAX_IDLE_TIME);
|
||||
|
|
|
@ -12,7 +12,7 @@ const crypto = require('crypto');
|
|||
const path = require('path');
|
||||
const tmpdir = require('os').tmpDir();
|
||||
|
||||
function getCacheFilePath(args) {
|
||||
function getCacheFilePath(...args) {
|
||||
args = Array.prototype.slice.call(args);
|
||||
const prefix = args.shift();
|
||||
|
||||
|
|
Loading…
Reference in New Issue