Return-Path: X-Original-To: apmail-cordova-dev-archive@www.apache.org Delivered-To: apmail-cordova-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AF2A1192A2 for ; Thu, 28 Apr 2016 07:27:35 +0000 (UTC) Received: (qmail 40802 invoked by uid 500); 28 Apr 2016 07:27:35 -0000 Delivered-To: apmail-cordova-dev-archive@cordova.apache.org Received: (qmail 40763 invoked by uid 500); 28 Apr 2016 07:27:35 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 40752 invoked by uid 99); 28 Apr 2016 07:27:35 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Apr 2016 07:27:35 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 07FFDDFAAB; Thu, 28 Apr 2016 07:27:35 +0000 (UTC) From: vladimir-kotikov To: dev@cordova.apache.org Reply-To: dev@cordova.apache.org References: In-Reply-To: Subject: [GitHub] cordova-android pull request: CB-11117: Use FileUpdater to optimiz... Content-Type: text/plain Message-Id: <20160428072735.07FFDDFAAB@git1-us-west.apache.org> Date: Thu, 28 Apr 2016 07:27:35 +0000 (UTC) Github user vladimir-kotikov commented on a diff in the pull request: https://github.com/apache/cordova-android/pull/295#discussion_r61383391 --- Diff: bin/templates/cordova/lib/prepare.js --- @@ -26,26 +26,43 @@ var AndroidManifest = require('./AndroidManifest'); var xmlHelpers = require('cordova-common').xmlHelpers; var CordovaError = require('cordova-common').CordovaError; var ConfigParser = require('cordova-common').ConfigParser; +var FileUpdater = require('cordova-common').FileUpdater; -module.exports.prepare = function (cordovaProject) { +module.exports.prepare = function (cordovaProject, options) { var self = this; + var platformResourcesDir = path.relative(cordovaProject.root, path.join(this.locations.root, 'res')); this._config = updateConfigFilesFrom(cordovaProject.projectConfig, this._munger, this.locations); // Update own www dir with project's www assets and plugins' assets and js-files - return Q.when(updateWwwFrom(cordovaProject, this.locations)) + return Q.when(updateWww.call(self, cordovaProject)) --- End diff -- I'd rather not to pass `this` reference to this method, especially if the only thing we need is a couple of properties from 'locations' object (`this.locations.platformWww` and `this.locations.www` at L120). Maybe just pass these properties as an arguments, or revert to previous signature? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org For additional commands, e-mail: dev-help@cordova.apache.org