override fun validate()

in common/src/main/kotlin/org/jetbrains/teamcity/sccache/backends.kt [70:81]


    override fun validate(result: MutableMap<String, String>): Boolean {
        if (bucket.isEmpty()) {
            result[S3Backend.BUCKET] = "Should not be empty"
            return false
        }
        if (iamCredentialsUrl.isNotEmpty() && (accessKey.isNotEmpty() || secretKey.isNotEmpty())) {
            result[S3Backend.IAM_CREDENTIALS_URL] = "Conflicts with Access Key and Secret Key"
            result[S3Backend.ACCESS_KEY] = "Conflicts with IAM Credentials Url"
            result[S3Backend.SECRET_KEY] = "Conflicts with IAM Credentials Url"
        }
        return true
    }