Commit d86fb033 authored by Viktor De Pasquale's avatar Viktor De Pasquale

Fixed conditions being inaccurately represented

parent 99d7d8dd
......@@ -14,7 +14,9 @@ interface MagiskQueryBuilder {
Builder::class.java.newInstance()
.apply(builder)
.toString()
.let { MagiskQuery(it) }
.let {
MagiskQuery(it)
}
}
}
......@@ -131,11 +133,11 @@ class Condition {
}
fun and(builder: Condition.() -> Unit) {
condition += " " + Condition().apply(builder).condition
condition = "($condition AND ${Condition().apply(builder).condition})"
}
fun or(builder: Condition.() -> Unit) {
condition += " " + Condition().apply(builder).condition
condition = "($condition OR ${Condition().apply(builder).condition})"
}
override fun toString(): String {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment