Skip to content

Commit

Permalink
upload image package
Browse files Browse the repository at this point in the history
  • Loading branch information
prachiFam committed Nov 24, 2019
1 parent d35844e commit 98b0411
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class AwsRegionHelper(private val context: Context, private val onUploadComplete

private fun initRegion(){

region1 = getRegionFor(REGION);
subRegion1 = getRegionFor(SUB_REGION);
region1 = getRegionFor(REGION)
subRegion1 = getRegionFor(SUB_REGION)

}

Expand All @@ -56,6 +56,7 @@ class AwsRegionHelper(private val context: Context, private val onUploadComplete
initRegion()

val credentialsProvider = CognitoCachingCredentialsProvider(context, IDENTITY_POOL_ID, region1)
TransferNetworkLossHandler.getInstance(context.applicationContext)

val amazonS3Client = AmazonS3Client(credentialsProvider)
amazonS3Client.setRegion(com.amazonaws.regions.Region.getRegion(subRegion1))
Expand All @@ -73,6 +74,7 @@ class AwsRegionHelper(private val context: Context, private val onUploadComplete
initRegion()

val credentialsProvider = CognitoCachingCredentialsProvider(context, IDENTITY_POOL_ID, region1)
TransferNetworkLossHandler.getInstance(context.applicationContext)

val amazonS3Client = AmazonS3Client(credentialsProvider)
amazonS3Client.setRegion(com.amazonaws.regions.Region.getRegion(subRegion1))
Expand Down

0 comments on commit 98b0411

Please sign in to comment.