Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix minor compiler warnings #37

Merged
merged 1 commit into from
May 27, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ fun getVersionName(git: Git, triple: VersionTriple): String {
}
}

val git = Git.open(File(rootDir, ".git"))
val git = Git.open(File(rootDir, ".git"))!!
val gitVersionTriple = describeVersion(git)
val gitVersionCode = getVersionCode(gitVersionTriple)
val gitVersionName = getVersionName(git, gitVersionTriple)
Expand Down
3 changes: 3 additions & 0 deletions app/magisk/updates/release/changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
* README.md: Remove mention of cloud storage. Android's Storage Access Framework does not support cloud storage when opening folders (Issue: #30, PR: #31, @chenxiaolong)
* Add full changelog text for updates from Magisk Manager (PR: #36, @chenxiaolong)

Non-user-facing changes:
* Fix minor compiler warnings (PR: #xx, @chenxiaolong)

### Version 1.3

* Write audio duration to FLAC metadata after recording is complete (Issue: #19, PR: #20, @chenxiaolong)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,6 @@ class CodecBottomSheetFragment : BottomSheetDialogFragment(),
}

companion object {
val TAG = CodecBottomSheetFragment::class.java.simpleName
val TAG: String = CodecBottomSheetFragment::class.java.simpleName
}
}
4 changes: 2 additions & 2 deletions app/src/main/java/com/chiller3/bcr/codec/Codecs.kt
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ import com.chiller3.bcr.Preferences

object Codecs {
val all: Array<Codec> = arrayOf(OpusCodec, AacCodec, FlacCodec)
val default: Codec = all.first { it.supported }
private val default: Codec = all.first { it.supported }

/** Find output codec by name. */
fun getByName(name: String): Codec? = all.find { it.name == name }
private fun getByName(name: String): Codec? = all.find { it.name == name }

/**
* Get the saved codec from the preferences or fall back to the default.
Expand Down