Panagiotis Triantafyllou

new keys

# {@link ly.warp.sdk.utils.WarplyProperty}
# The app uuid the warply sdk need to connect to the engage server
# cosmote demo app f83dfde1145e4c2da69793abb2f579af
# dev f83dfde1145e4c2da69793abb2f579af
# prod 0086a2088301440792091b9f814c2267
Uuid=f83dfde1145e4c2da69793abb2f579af
# If we need to see logs in Logcat
......
......@@ -36,7 +36,7 @@ public class SplashActivity extends BaseActivity {
public void onWarplyReady() {
if (!WarplyDBHelper.getInstance(SplashActivity.this).isTableNotEmpty("auth")) {
WarplyManager.getCosmoteUser(new WarplyCosmoteUserRequest()
.setGuid("6010962478"), //6012049321, 6012049322, 6012049323, 7000000831 history, 7000000826, 7000000831 shared coupons, prod 6006552990
.setGuid("7000000826"), //6012049321, 6012049322, 6012049323, 7000000831 history, 7000000826, 7000000831 shared coupons, prod 6006552990
mLoginReceiver);
} else {
startNextActivity();
......
......@@ -2,7 +2,7 @@ apply plugin: 'com.android.library'
ext {
PUBLISH_GROUP_ID = 'ly.warp'
PUBLISH_VERSION = '4.5.4-cosbeta86'
PUBLISH_VERSION = '4.5.4-cosbeta87'
PUBLISH_ARTIFACT_ID = 'warply-android-sdk'
}
......
......@@ -154,15 +154,23 @@ public enum Warply {
* not, it throws a runtime exception with a message describing the reason
*/
private void isInitializedOrThrow() {
if (mContext == null)
if (mContext == null) {
WarpUtils.log("Warply has not been initialized, call init(Context) first");
if (mContext.get() == null)
return;
}
if (mContext.get() == null) {
WarpUtils.log("Warply has not been initialized, call init(Context) first");
return;
}
String apiKey = WarplyProperty.getAppUuid(mContext.get());
if (apiKey == null)
if (apiKey == null) {
WarpUtils.log("Warply application UUID has not been set in the Manifest");
if ((apiKey.length() != 32) && (apiKey.length() != 36))
return;
}
if ((apiKey.length() != 32) && (apiKey.length() != 36)) {
WarpUtils.log("Warply application UUID has not been set correclty in the Manifest, key got: " + apiKey);
return;
}
}
/**
......
......@@ -366,7 +366,7 @@ public class GiftsForYouActivity extends Activity implements View.OnClickListene
seasonalCLick.setTitle(dataItem.getSeasonalList().getTitle());
seasonalCLick.setLoyaltyPackageId(dataItem.getSeasonalList().getLoyaltyPackageId());
seasonalCLick.setImageUrl(dataItem.getSeasonalList().getImageUrl());
seasonalCLick.setContext(GiftsForYouActivity.this);
seasonalCLick.setContext(this);
EventBus.getDefault().post(new WarplyEventBusManager(seasonalCLick));
LoyaltySDKFirebaseEventModel analyticsEvent = new LoyaltySDKFirebaseEventModel();
......@@ -588,7 +588,7 @@ public class GiftsForYouActivity extends Activity implements View.OnClickListene
try {
JSONObject extraFields = WarpJSONParser.getJSONFromString(camp.getExtraFields());
if (extraFields != null) {
if (extraFields.length() == 0 || !(/*extraFields.has("ccms_offer") || */extraFields.has("type"))) {
if (extraFields.length() == 0 || !(extraFields.has("ccms_offer") || extraFields.has("type"))) {
gfyList.add(camp);
}
}
......
......@@ -528,7 +528,7 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
try {
JSONObject extraFields = WarpJSONParser.getJSONFromString(camp.getExtraFields());
if (extraFields != null) {
if (extraFields.length() == 0 || !(/*extraFields.has("ccms_offer") || */extraFields.has("type"))) {
if (extraFields.length() == 0 || !(extraFields.has("ccms_offer") || extraFields.has("type"))) {
mfyList.add(camp);
}
}
......
......@@ -89,7 +89,7 @@ public class WarplyHealthService extends Service implements SensorEventListener
mSensorManager = (SensorManager) getSystemService(Context.SENSOR_SERVICE);
mSensor = mSensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER);
// registerStepSensor();
Warply.getInitializer(this).init();
// Warply.getInitializer(this).init();
WarplyManager.getPacingDetails(new PacingDetailsRequest(), mPacingCallback);
}
......
......@@ -1146,7 +1146,7 @@ public class WarplyManagerHelper {
try {
JSONObject extraFields = WarpJSONParser.getJSONFromString(camp.getExtraFields());
if (extraFields != null) {
if (extraFields.length() == 0 || !(/*extraFields.has("ccms_offer") || */extraFields.has("type"))) {
if (extraFields.length() == 0 || !(extraFields.has("ccms_offer") || extraFields.has("type"))) {
mCampaignList.add(camp);
}
}
......