You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ag...@apache.org on 2015/03/03 02:38:26 UTC

[2/2] android commit: Add an `isSecretEstablished()` getter to CordovaBridge

Add an `isSecretEstablished()` getter to CordovaBridge

Not being used, but might be of use to an Engine plugin or a Whitelist
plugin.


Project: http://git-wip-us.apache.org/repos/asf/cordova-android/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-android/commit/1ad280db
Tree: http://git-wip-us.apache.org/repos/asf/cordova-android/tree/1ad280db
Diff: http://git-wip-us.apache.org/repos/asf/cordova-android/diff/1ad280db

Branch: refs/heads/master
Commit: 1ad280db985cd1e6176f194407ecf9272ad06aae
Parents: 035c3ad
Author: Andrew Grieve <ag...@chromium.org>
Authored: Mon Mar 2 20:37:33 2015 -0500
Committer: Andrew Grieve <ag...@chromium.org>
Committed: Mon Mar 2 20:37:33 2015 -0500

----------------------------------------------------------------------
 framework/src/org/apache/cordova/CordovaBridge.java | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-android/blob/1ad280db/framework/src/org/apache/cordova/CordovaBridge.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/CordovaBridge.java b/framework/src/org/apache/cordova/CordovaBridge.java
index 50eb901..b9c6098 100644
--- a/framework/src/org/apache/cordova/CordovaBridge.java
+++ b/framework/src/org/apache/cordova/CordovaBridge.java
@@ -107,6 +107,10 @@ public class CordovaBridge {
         expectedBridgeSecret = -1;
     }
 
+    public boolean isSecretEstablished() {
+        return expectedBridgeSecret != -1;
+    }
+
     /** Called by cordova.js to initialize the bridge. */
     int generateBridgeSecret() {
         SecureRandom randGen = new SecureRandom();


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org