cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From omefire <...@git.apache.org>
Subject [GitHub] cordova-lib pull request: Change cordova-lib to execute plugin hoo...
Date Sun, 16 Aug 2015 12:52:28 GMT
Github user omefire commented on a diff in the pull request:

    https://github.com/apache/cordova-lib/pull/236#discussion_r37145507
  
    --- Diff: cordova-lib/src/hooks/HooksRunner.js ---
    @@ -60,11 +64,23 @@ HooksRunner.prototype.fire = function fire(hook, opts) {
     };
     
     /**
    + * Tries to create a CordovaHooksRunner for passed project root.
    + * @constructor
    + */
    +function CordovaHooksRunner(projectRoot) {
    +    DefaultHooksRunner.call(this, projectRoot);
    +    var root = cordovaUtil.isCordova(projectRoot);
    +    if (!root) throw new CordovaError('Not a Cordova project ("' + projectRoot + '"),
can\'t use hooks.');
    --- End diff --
    
    :nit please use `if (...) { } else { }` (with curly braces).


---
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


Mime
View raw message