@@ -56,8 +56,8 @@ public class AdColonyPlugin extends CordovaPlugin implements AdColonyAdListener,
56
56
57
57
private CallbackContext _videoAdCallbackContext ;
58
58
private CallbackContext _nativeAdCallbackContext ;
59
- private boolean _isPreparingVideoAd ;
60
- private boolean _hasInitialized ;
59
+ private boolean _isPreparingVideoAd = false ;
60
+ private boolean _hasInitialized = false ;
61
61
62
62
@ Override
63
63
public boolean execute (String action , JSONArray inputs , CallbackContext callbackContext ) throws JSONException
@@ -126,17 +126,17 @@ private static String[] toStringArray(JSONArray jsonArray) throws JSONException
126
126
127
127
private void execInitialize (JSONArray inputs , CallbackContext callbackContext ) throws JSONException {
128
128
String optionString = "" ;
129
- // try {
130
- JSONObject options = inputs .getJSONObject (2 );
131
- String deviceId = options .getString ("deviceId" );
132
- String customId = options .getString ("customId" );
133
- if (deviceId != null ) AdColony .setDeviceID ( deviceId );
134
- if (customId != null ) AdColony .setCustomID ( customId );
135
- optionString = options .getString ("optionString" );
136
- // }
137
- // catch (JSONException exception) {
129
+ try {
130
+ JSONObject options = inputs .getJSONObject (2 );
131
+ String deviceId = options .getString ("deviceId" );
132
+ String customId = options .getString ("customId" );
133
+ if (deviceId != null ) AdColony .setDeviceID ( deviceId );
134
+ if (customId != null ) AdColony .setCustomID ( customId );
135
+ optionString = options .getString ("optionString" );
136
+ }
137
+ catch (JSONException exception ) {
138
138
// Do nothing
139
- // }
139
+ }
140
140
String appId = inputs .getString (0 );
141
141
String [] zoneIds = toStringArray (inputs .getJSONArray (1 ));
142
142
AdColony .configure ( this .cordova .getActivity (), optionString , appId , zoneIds );
0 commit comments