Skip to content

Commit

Permalink
fix(grpc): catch exception using status.code instead of status
Browse files Browse the repository at this point in the history
  • Loading branch information
ingvaar committed Apr 1, 2022
1 parent 0ea7590 commit 286555b
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -66,7 +66,7 @@ class CosmosSourceTask : SourceTask() {
onFailure = {
// If the status of the exception is INVALID_ARGUMENT,
// it means that we reached the end of the chain
if ((it is StatusException) && (it.status == Status.INVALID_ARGUMENT)) return@runBlocking
if ((it is StatusException) && (it.status.code == Status.Code.INVALID_ARGUMENT)) return@runBlocking
else throw it
}
)
Expand Down

0 comments on commit 286555b

Please sign in to comment.