Skip to content

Commit 0626ec1

Browse files
committed
Typos fixed
1 parent ccd0229 commit 0626ec1

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

kotlinx-coroutines-core/common/src/CoroutineScope.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ public inline fun CoroutineScope.cancel() {
215215
* Throws [IllegalStateException] if the context does not have a job in it.
216216
*
217217
* If the job is no longer active, throws [CancellationException].
218-
* If the job was cancelled, thrown exception contains original cancellation cause.
218+
* If the job was cancelled, thrown exception contains the original cancellation cause.
219219
*
220220
* This method is a drop-in replacement for the following code, but with more precise exception:
221221
* ```

kotlinx-coroutines-core/common/src/Job.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,7 @@ public fun CoroutineContext.cancel(): Unit {
539539
/**
540540
* Ensures that current job is [active][Job.isActive].
541541
* If the job is no longer active, throws [CancellationException].
542-
* If the job was cancelled, thrown exception contains original cancellation cause.
542+
* If the job was cancelled, thrown exception contains the original cancellation cause.
543543
*
544544
* This method is a drop-in replacement for the following code, but with more precise exception:
545545
* ```
@@ -557,7 +557,7 @@ public fun Job.ensureActive(): Unit {
557557
* Throws [IllegalStateException] if the context does not have a job in it.
558558
*
559559
* If the job is no longer active, throws [CancellationException].
560-
* If the job was cancelled, thrown exception contains original cancellation cause.
560+
* If the job was cancelled, thrown exception contains the original cancellation cause.
561561
*
562562
* This method is a drop-in replacement for the following code, but with more precise exception:
563563
* ```
@@ -567,7 +567,7 @@ public fun Job.ensureActive(): Unit {
567567
* ```
568568
*/
569569
public fun CoroutineContext.ensureActive(): Unit {
570-
val job = get(Job) ?: error("Context cannot be check for liveness because it does not have a job: $this")
570+
val job = get(Job) ?: error("Context cannot be checked for liveness because it does not have a job: $this")
571571
job.ensureActive()
572572
}
573573

0 commit comments

Comments
 (0)