get requests on Earn
This commit is contained in:
parent
2e4b0ec0a6
commit
958ed62b45
|
|
@ -86,7 +86,9 @@ public class EarnerInterface {
|
|||
new Thread(() -> {
|
||||
try {
|
||||
JsonObject result = getLastSubscription(exchange, true);
|
||||
new Handler(Looper.getMainLooper()).post(() -> showJsonDialog(result, context));
|
||||
String dialogTitle = "Last subscription";
|
||||
String dialogMessage = result.get("last_subscription").toString();
|
||||
new Handler(Looper.getMainLooper()).post(() -> showSimpleDialog(dialogTitle, dialogMessage, context));
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
new Handler(Looper.getMainLooper()).post(() -> Toast.makeText(context, "Failed to get last subscription", Toast.LENGTH_SHORT).show());
|
||||
|
|
@ -98,7 +100,9 @@ public class EarnerInterface {
|
|||
new Thread(() -> {
|
||||
try {
|
||||
JsonObject result = getLastRedemption(exchange, true);
|
||||
new Handler(Looper.getMainLooper()).post(() -> showJsonDialog(result, context));
|
||||
String dialogTitle = "Last redemption";
|
||||
String dialogMessage = result.get("last_redemption").toString();
|
||||
new Handler(Looper.getMainLooper()).post(() -> showSimpleDialog(dialogTitle, dialogMessage, context));
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
new Handler(Looper.getMainLooper()).post(() -> Toast.makeText(context, "Failed to get last redemption", Toast.LENGTH_SHORT).show());
|
||||
|
|
|
|||
Loading…
Reference in New Issue