Skip to content

Commit

Permalink
feat: UBoolean?.orUnspecified
Browse files Browse the repository at this point in the history
  • Loading branch information
oxyroid committed Oct 6, 2023
1 parent aaa5839 commit 8016c9e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions core/src/main/java/com/m3u/core/unspecified/UBoolean.kt
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,6 @@ enum class UBoolean {

val Boolean.ub: UBoolean get() = if (this) UBoolean.True else UBoolean.False

val UBoolean?.orUnspecified: UBoolean get() = this ?: UBoolean.Unspecified

val UBoolean.isUnspecified: Boolean get() = this == UBoolean.Unspecified

0 comments on commit 8016c9e

Please sign in to comment.