diff --git a/AmplifyPlugins/Storage/Sources/AWSS3StoragePlugin/AWSS3StoragePlugin+Configure.swift b/AmplifyPlugins/Storage/Sources/AWSS3StoragePlugin/AWSS3StoragePlugin+Configure.swift index f6ee4f1a7d..9b40e63906 100644 --- a/AmplifyPlugins/Storage/Sources/AWSS3StoragePlugin/AWSS3StoragePlugin+Configure.swift +++ b/AmplifyPlugins/Storage/Sources/AWSS3StoragePlugin/AWSS3StoragePlugin+Configure.swift @@ -37,6 +37,7 @@ extension AWSS3StoragePlugin { do { let authService = AWSAuthService() + let defaultAccessLevel = try configClosures.retrieveDefaultAccessLevel() let storageService = try AWSS3StorageService(authService: authService, region: configClosures.retrieveRegion(), bucket: configClosures.retrieveBucket(), @@ -45,7 +46,7 @@ extension AWSS3StoragePlugin { configure(storageService: storageService, authService: authService, - defaultAccessLevel: try configClosures.retrieveDefaultAccessLevel()) + defaultAccessLevel: defaultAccessLevel) } catch let storageError as StorageError { throw storageError } catch {