mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Replace underscore _.clone with Object.assign.
This commit is contained in:
@@ -19,7 +19,6 @@ import {
|
||||
isLoggedIn,
|
||||
maybePrintRegistrationLink,
|
||||
} from './auth.js';
|
||||
import { clone } from 'underscore';
|
||||
import { recordPackages } from './stats.js';
|
||||
import { Console } from '../console/console.js';
|
||||
|
||||
@@ -71,8 +70,8 @@ const CAPABILITIES = ['showDeployMessages', 'canTransferAuthorization'];
|
||||
// body, or a generic 'try again later' message, as appropriate
|
||||
|
||||
function deployRpc(options) {
|
||||
options = clone(options);
|
||||
options.headers = clone(options.headers || {});
|
||||
options = Object.assign({}, options);
|
||||
options.headers = Object.assign({}, options.headers || {});
|
||||
if (options.headers.cookie) {
|
||||
throw new Error("sorry, can't combine cookie headers yet");
|
||||
}
|
||||
@@ -165,7 +164,7 @@ function deployRpc(options) {
|
||||
// the user to log in with a username and password and then resend the
|
||||
// RPC.
|
||||
function authedRpc(options) {
|
||||
var rpcOptions = clone(options);
|
||||
var rpcOptions = Object.assign({}, options);
|
||||
var preflight = rpcOptions.preflight;
|
||||
delete rpcOptions.preflight;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user