From 35fc385a502bc3053c295fb3b90eb82b2a1a8a1a Mon Sep 17 00:00:00 2001 From: rjsuzuki Date: Mon, 15 Jul 2024 13:39:02 -0700 Subject: [PATCH] Lint --- .../google/store/sales/GoogleResponse.kt | 26 +++++++++---------- .../google/store/sales/GoogleSales.kt | 16 ++++++------ 2 files changed, 21 insertions(+), 21 deletions(-) diff --git a/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleResponse.kt b/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleResponse.kt index 3e5ff78..740bfd1 100644 --- a/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleResponse.kt +++ b/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleResponse.kt @@ -38,79 +38,79 @@ object GoogleResponse { BillingClient.BillingResponseCode.OK -> { Logger.d( TAG, - "${BILLING_RESPONSE}: " + "\n " + BillingClient.BillingResponseCode.OK.toString() + "\n message: OK" + "$BILLING_RESPONSE: " + "\n " + BillingClient.BillingResponseCode.OK.toString() + "\n message: OK" ) } BillingClient.BillingResponseCode.USER_CANCELED -> { Logger.w( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.USER_CANCELED.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.USER_CANCELED.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.BILLING_UNAVAILABLE -> { Logger.w( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.BILLING_UNAVAILABLE.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.BILLING_UNAVAILABLE.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.DEVELOPER_ERROR -> { Logger.e( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.DEVELOPER_ERROR.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.DEVELOPER_ERROR.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.ERROR -> { Logger.e( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.ERROR.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.ERROR.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.FEATURE_NOT_SUPPORTED -> { Logger.w( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.FEATURE_NOT_SUPPORTED.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.FEATURE_NOT_SUPPORTED.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.ITEM_ALREADY_OWNED -> { Logger.w( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.ITEM_ALREADY_OWNED.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.ITEM_ALREADY_OWNED.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.ITEM_NOT_OWNED -> { Logger.w( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.ITEM_NOT_OWNED.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.ITEM_NOT_OWNED.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.ITEM_UNAVAILABLE -> { Logger.w( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.ITEM_UNAVAILABLE.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.ITEM_UNAVAILABLE.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.SERVICE_DISCONNECTED -> { Logger.w( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.SERVICE_DISCONNECTED.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.SERVICE_DISCONNECTED.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.SERVICE_TIMEOUT -> { Logger.e( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.SERVICE_TIMEOUT.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.SERVICE_TIMEOUT.toString() + "\n message: ${billingResult.debugMessage}" ) } BillingClient.BillingResponseCode.SERVICE_UNAVAILABLE -> { Logger.e( TAG, - "${BILLING_RESPONSE}: " + "\n code: " + BillingClient.BillingResponseCode.SERVICE_UNAVAILABLE.toString() + "\n message: ${billingResult.debugMessage}" + "$BILLING_RESPONSE: " + "\n code: " + BillingClient.BillingResponseCode.SERVICE_UNAVAILABLE.toString() + "\n message: ${billingResult.debugMessage}" ) } else -> { Logger.wtf( TAG, - "Unhandled ${BILLING_RESPONSE}: ${billingResult?.responseCode}" + "Unhandled $BILLING_RESPONSE: ${billingResult?.responseCode}" ) } } diff --git a/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleSales.kt b/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleSales.kt index a4c1106..de138e1 100644 --- a/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleSales.kt +++ b/lib/google/src/main/java/com/zuko/billingz/google/store/sales/GoogleSales.kt @@ -141,8 +141,8 @@ class GoogleSales( Logger.d( TAG, "startOrder => " + - "\n product: $product," + - "\n options: $options" + "\n product: $product," + + "\n options: $options" ) if (product is GoogleProduct && client is GoogleClient) { @@ -273,9 +273,9 @@ class GoogleSales( Logger.d( TAG, "startSubscriptionPurchaseFlow =>" + - "\n skuDetails: $skuDetails," + - "\n productDetails: $productDetails," + - "\n options: $options" + "\n skuDetails: $skuDetails," + + "\n productDetails: $productDetails," + + "\n options: $options" ) if (activity == null || (skuDetails == null && productDetails == null) || billingClient == null) { return BillingResult.newBuilder() @@ -382,9 +382,9 @@ class GoogleSales( Logger.d( TAG, "startInAppPurchaseFlow =>" + - "\n skuDetails: $skuDetails," + - "\n productDetails: $productDetails," + - "\n options: $options" + "\n skuDetails: $skuDetails," + + "\n productDetails: $productDetails," + + "\n options: $options" ) if (activity == null || (skuDetails == null && productDetails == null) || billingClient == null) { return BillingResult.newBuilder()