Changed runTask to bukkitRun

Changed the runTask method to bukkitRun and added documentation
This commit is contained in:
bluefireoly
2020-10-18 16:53:10 +02:00
parent c872a94fb2
commit dcdb817a7c
2 changed files with 9 additions and 5 deletions

View File

@@ -104,7 +104,11 @@ fun task(
}
fun runTask(sync: Boolean, runnable: () -> Unit) {
/**
* Executes the given [runnable] either
* sync or async (specified by the [sync] parameter).
*/
fun bukkitRun(sync: Boolean, runnable: () -> Unit) {
if (sync) {
sync(runnable)
} else {